{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "        <script type=\"text/javascript\">\n",
       "        window.PlotlyConfig = {MathJaxConfig: 'local'};\n",
       "        if (window.MathJax && window.MathJax.Hub && window.MathJax.Hub.Config) {window.MathJax.Hub.Config({SVG: {font: \"STIX-Web\"}});}\n",
       "        if (typeof require !== 'undefined') {\n",
       "        require.undef(\"plotly\");\n",
       "        requirejs.config({\n",
       "            paths: {\n",
       "                'plotly': ['https://cdn.plot.ly/plotly-2.31.1.min']\n",
       "            }\n",
       "        });\n",
       "        require(['plotly'], function(Plotly) {\n",
       "            window._Plotly = Plotly;\n",
       "        });\n",
       "        }\n",
       "        </script>\n",
       "        "
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "['Pokemon.csv', 'telecom_churn.csv', 'timesData.csv']\n"
     ]
    }
   ],
   "source": [
    "# This Python 3 environment comes with many helpful analytics libraries installed\n",
    "# It is defined by the kaggle/python docker image: https://github.com/kaggle/docker-python\n",
    "# For example, here's several helpful packages to load in \n",
    "\n",
    "import numpy as np # linear algebra\n",
    "import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)\n",
    "\n",
    "# plotly\n",
    "# import plotly.plotly as py\n",
    "from plotly.offline import init_notebook_mode, iplot, plot\n",
    "import plotly as py\n",
    "init_notebook_mode(connected=True)\n",
    "import plotly.graph_objs as go\n",
    "\n",
    "# word cloud library\n",
    "from wordcloud import WordCloud\n",
    "\n",
    "# matplotlib\n",
    "import matplotlib.pyplot as plt\n",
    "# Input data files are available in the \"../input/\" directory.\n",
    "# For example, running this (by clicking run or pressing Shift+Enter) will list the files in the input directory\n",
    "\n",
    "import os\n",
    "print(os.listdir(\"data/\"))\n",
    "\n",
    "# Any results you write to the current directory are saved as output."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [],
   "source": [
    "timesData = pd.read_csv(\"data/timesData.csv\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "<class 'pandas.core.frame.DataFrame'>\n",
      "RangeIndex: 2603 entries, 0 to 2602\n",
      "Data columns (total 14 columns):\n",
      " #   Column                  Non-Null Count  Dtype  \n",
      "---  ------                  --------------  -----  \n",
      " 0   world_rank              2603 non-null   object \n",
      " 1   university_name         2603 non-null   object \n",
      " 2   country                 2603 non-null   object \n",
      " 3   teaching                2603 non-null   float64\n",
      " 4   international           2603 non-null   object \n",
      " 5   research                2603 non-null   float64\n",
      " 6   citations               2603 non-null   float64\n",
      " 7   income                  2603 non-null   object \n",
      " 8   total_score             2603 non-null   object \n",
      " 9   num_students            2544 non-null   object \n",
      " 10  student_staff_ratio     2544 non-null   float64\n",
      " 11  international_students  2536 non-null   object \n",
      " 12  female_male_ratio       2370 non-null   object \n",
      " 13  year                    2603 non-null   int64  \n",
      "dtypes: float64(4), int64(1), object(9)\n",
      "memory usage: 284.8+ KB\n"
     ]
    }
   ],
   "source": [
    "timesData.info()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>world_rank</th>\n",
       "      <th>university_name</th>\n",
       "      <th>country</th>\n",
       "      <th>teaching</th>\n",
       "      <th>international</th>\n",
       "      <th>research</th>\n",
       "      <th>citations</th>\n",
       "      <th>income</th>\n",
       "      <th>total_score</th>\n",
       "      <th>num_students</th>\n",
       "      <th>student_staff_ratio</th>\n",
       "      <th>international_students</th>\n",
       "      <th>female_male_ratio</th>\n",
       "      <th>year</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>1</td>\n",
       "      <td>Harvard University</td>\n",
       "      <td>United States of America</td>\n",
       "      <td>99.7</td>\n",
       "      <td>72.4</td>\n",
       "      <td>98.7</td>\n",
       "      <td>98.8</td>\n",
       "      <td>34.5</td>\n",
       "      <td>96.1</td>\n",
       "      <td>20,152</td>\n",
       "      <td>8.9</td>\n",
       "      <td>25%</td>\n",
       "      <td>NaN</td>\n",
       "      <td>2011</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>2</td>\n",
       "      <td>California Institute of Technology</td>\n",
       "      <td>United States of America</td>\n",
       "      <td>97.7</td>\n",
       "      <td>54.6</td>\n",
       "      <td>98.0</td>\n",
       "      <td>99.9</td>\n",
       "      <td>83.7</td>\n",
       "      <td>96.0</td>\n",
       "      <td>2,243</td>\n",
       "      <td>6.9</td>\n",
       "      <td>27%</td>\n",
       "      <td>33 : 67</td>\n",
       "      <td>2011</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>3</td>\n",
       "      <td>Massachusetts Institute of Technology</td>\n",
       "      <td>United States of America</td>\n",
       "      <td>97.8</td>\n",
       "      <td>82.3</td>\n",
       "      <td>91.4</td>\n",
       "      <td>99.9</td>\n",
       "      <td>87.5</td>\n",
       "      <td>95.6</td>\n",
       "      <td>11,074</td>\n",
       "      <td>9.0</td>\n",
       "      <td>33%</td>\n",
       "      <td>37 : 63</td>\n",
       "      <td>2011</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>4</td>\n",
       "      <td>Stanford University</td>\n",
       "      <td>United States of America</td>\n",
       "      <td>98.3</td>\n",
       "      <td>29.5</td>\n",
       "      <td>98.1</td>\n",
       "      <td>99.2</td>\n",
       "      <td>64.3</td>\n",
       "      <td>94.3</td>\n",
       "      <td>15,596</td>\n",
       "      <td>7.8</td>\n",
       "      <td>22%</td>\n",
       "      <td>42 : 58</td>\n",
       "      <td>2011</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>5</td>\n",
       "      <td>Princeton University</td>\n",
       "      <td>United States of America</td>\n",
       "      <td>90.9</td>\n",
       "      <td>70.3</td>\n",
       "      <td>95.4</td>\n",
       "      <td>99.9</td>\n",
       "      <td>-</td>\n",
       "      <td>94.2</td>\n",
       "      <td>7,929</td>\n",
       "      <td>8.4</td>\n",
       "      <td>27%</td>\n",
       "      <td>45 : 55</td>\n",
       "      <td>2011</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "  world_rank                        university_name                   country  \\\n",
       "0          1                     Harvard University  United States of America   \n",
       "1          2     California Institute of Technology  United States of America   \n",
       "2          3  Massachusetts Institute of Technology  United States of America   \n",
       "3          4                    Stanford University  United States of America   \n",
       "4          5                   Princeton University  United States of America   \n",
       "\n",
       "   teaching international  research  citations income total_score  \\\n",
       "0      99.7          72.4      98.7       98.8   34.5        96.1   \n",
       "1      97.7          54.6      98.0       99.9   83.7        96.0   \n",
       "2      97.8          82.3      91.4       99.9   87.5        95.6   \n",
       "3      98.3          29.5      98.1       99.2   64.3        94.3   \n",
       "4      90.9          70.3      95.4       99.9      -        94.2   \n",
       "\n",
       "  num_students  student_staff_ratio international_students female_male_ratio  \\\n",
       "0       20,152                  8.9                    25%               NaN   \n",
       "1        2,243                  6.9                    27%           33 : 67   \n",
       "2       11,074                  9.0                    33%           37 : 63   \n",
       "3       15,596                  7.8                    22%           42 : 58   \n",
       "4        7,929                  8.4                    27%           45 : 55   \n",
       "\n",
       "   year  \n",
       "0  2011  \n",
       "1  2011  \n",
       "2  2011  \n",
       "3  2011  \n",
       "4  2011  "
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "timesData.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.plotly.v1+json": {
       "config": {
        "linkText": "Export to plot.ly",
        "plotlyServerURL": "https://plot.ly",
        "showLink": false
       },
       "data": [
        {
         "marker": {
          "color": "rgba(16, 112, 2, 0.8)"
         },
         "mode": "lines",
         "name": "citations",
         "text": [
          "Harvard University",
          "California Institute of Technology",
          "Massachusetts Institute of Technology",
          "Stanford University",
          "Princeton University",
          "University of Cambridge",
          "University of Oxford",
          "University of California, Berkeley",
          "Imperial College London",
          "Yale University",
          "University of California, Los Angeles",
          "University of Chicago",
          "Johns Hopkins University",
          "Cornell University",
          "ETH Zurich – Swiss Federal Institute of Technology Zurich",
          "University of Michigan",
          "University of Toronto",
          "Columbia University",
          "University of Pennsylvania",
          "Carnegie Mellon University",
          "University of Hong Kong",
          "University College London",
          "University of Washington",
          "Duke University",
          "Northwestern University",
          "University of Tokyo",
          "Georgia Institute of Technology",
          "Pohang University of Science and Technology",
          "University of California, Santa Barbara",
          "University of British Columbia",
          "University of North Carolina at Chapel Hill",
          "University of California, San Diego",
          "University of Illinois at Urbana-Champaign",
          "National University of Singapore",
          "McGill University",
          "University of Melbourne",
          "Peking University",
          "Washington University in St Louis",
          "École Polytechnique",
          "University of Edinburgh",
          "Hong Kong University of Science and Technology",
          "École Normale Supérieure",
          "Australian National University",
          "Karolinska Institute",
          "University of Göttingen",
          "University of Wisconsin",
          "Rice University",
          "École Polytechnique Fédérale de Lausanne",
          "University of California, Irvine",
          "University of Science and Technology of China",
          "Vanderbilt University",
          "University of Minnesota",
          "Tufts University",
          "University of California, Davis",
          "Brown University",
          "University of Massachusetts",
          "Kyoto University",
          "Tsinghua University",
          "Boston University",
          "New York University",
          "Emory University",
          "LMU Munich",
          "University of Notre Dame",
          "University of Pittsburgh",
          "Case Western Reserve University",
          "Ohio State University",
          "University of Colorado Boulder",
          "University of Bristol",
          "University of California, Santa Cruz",
          "Yeshiva University",
          "University of Sydney",
          "University of Virginia",
          "University of Adelaide",
          "University of Southern California",
          "William & Mary",
          "Trinity College Dublin",
          "King’s College London",
          "Stony Brook University",
          "Korea Advanced Institute of Science and Technology (KAIST)",
          "University of Sussex",
          "The University of Queensland",
          "University of York",
          "Heidelberg University",
          "University of Utah",
          "Durham University",
          "London School of Economics and Political Science",
          "University of Manchester",
          "Royal Holloway, University of London",
          "Lund University",
          "University of Southampton",
          "University of Zurich",
          "Wake Forest University",
          "McMaster University",
          "University College Dublin",
          "George Washington University",
          "University of Arizona",
          "University of Basel",
          "University of Maryland, College Park",
          "Dartmouth College",
          "École Normale Supérieure de Lyon"
         ],
         "type": "scatter",
         "x": [
          "1",
          "2",
          "3",
          "4",
          "5",
          "6",
          "6",
          "8",
          "9",
          "10",
          "11",
          "12",
          "13",
          "14",
          "15",
          "15",
          "17",
          "18",
          "19",
          "20",
          "21",
          "22",
          "23",
          "24",
          "25",
          "26",
          "27",
          "28",
          "29",
          "30",
          "30",
          "32",
          "33",
          "34",
          "35",
          "36",
          "37",
          "38",
          "39",
          "40",
          "41",
          "42",
          "43",
          "43",
          "43",
          "43",
          "47",
          "48",
          "49",
          "49",
          "51",
          "52",
          "53",
          "54",
          "55",
          "56",
          "57",
          "58",
          "59",
          "60",
          "61",
          "61",
          "63",
          "64",
          "65",
          "66",
          "67",
          "68",
          "68",
          "68",
          "71",
          "72",
          "73",
          "73",
          "75",
          "76",
          "77",
          "78",
          "79",
          "79",
          "81",
          "81",
          "83",
          "83",
          "85",
          "86",
          "87",
          "88",
          "89",
          "90",
          "90",
          "90",
          "93",
          "94",
          "95",
          "95",
          "95",
          "98",
          "99",
          "100"
         ],
         "y": [
          98.8,
          99.9,
          99.9,
          99.2,
          99.9,
          94,
          95.1,
          97.8,
          88.3,
          91.5,
          93.2,
          96.9,
          92.3,
          88.1,
          83.1,
          84.1,
          82.2,
          92.6,
          93.6,
          95.7,
          96.1,
          80.6,
          95.9,
          92.3,
          95.3,
          58.1,
          83.2,
          96.5,
          98.8,
          80.3,
          85,
          90.8,
          72.9,
          78.7,
          69,
          83.3,
          72.2,
          88.6,
          91.4,
          86.8,
          98.2,
          95.7,
          81,
          62.3,
          92.5,
          83.4,
          99.1,
          83.8,
          91.6,
          92.7,
          78.1,
          76.4,
          83.9,
          68.8,
          77.7,
          67.9,
          46.3,
          52.7,
          91.4,
          82.9,
          77.8,
          76.4,
          89.1,
          78.3,
          66,
          67.2,
          83.4,
          80.9,
          99.6,
          74.4,
          64.3,
          68.6,
          90.5,
          71.9,
          95.6,
          84.4,
          72.1,
          85.8,
          45.5,
          91.6,
          69,
          81.9,
          70.3,
          72,
          91,
          51.6,
          59.2,
          93.2,
          67.6,
          72.9,
          65,
          79.2,
          68.5,
          86.3,
          70.2,
          70.1,
          78.3,
          79.2,
          79.7,
          88.8
         ]
        },
        {
         "marker": {
          "color": "rgba(80, 26, 80, 0.8)"
         },
         "mode": "lines+markers",
         "name": "teaching",
         "text": [
          "Harvard University",
          "California Institute of Technology",
          "Massachusetts Institute of Technology",
          "Stanford University",
          "Princeton University",
          "University of Cambridge",
          "University of Oxford",
          "University of California, Berkeley",
          "Imperial College London",
          "Yale University",
          "University of California, Los Angeles",
          "University of Chicago",
          "Johns Hopkins University",
          "Cornell University",
          "ETH Zurich – Swiss Federal Institute of Technology Zurich",
          "University of Michigan",
          "University of Toronto",
          "Columbia University",
          "University of Pennsylvania",
          "Carnegie Mellon University",
          "University of Hong Kong",
          "University College London",
          "University of Washington",
          "Duke University",
          "Northwestern University",
          "University of Tokyo",
          "Georgia Institute of Technology",
          "Pohang University of Science and Technology",
          "University of California, Santa Barbara",
          "University of British Columbia",
          "University of North Carolina at Chapel Hill",
          "University of California, San Diego",
          "University of Illinois at Urbana-Champaign",
          "National University of Singapore",
          "McGill University",
          "University of Melbourne",
          "Peking University",
          "Washington University in St Louis",
          "École Polytechnique",
          "University of Edinburgh",
          "Hong Kong University of Science and Technology",
          "École Normale Supérieure",
          "Australian National University",
          "Karolinska Institute",
          "University of Göttingen",
          "University of Wisconsin",
          "Rice University",
          "École Polytechnique Fédérale de Lausanne",
          "University of California, Irvine",
          "University of Science and Technology of China",
          "Vanderbilt University",
          "University of Minnesota",
          "Tufts University",
          "University of California, Davis",
          "Brown University",
          "University of Massachusetts",
          "Kyoto University",
          "Tsinghua University",
          "Boston University",
          "New York University",
          "Emory University",
          "LMU Munich",
          "University of Notre Dame",
          "University of Pittsburgh",
          "Case Western Reserve University",
          "Ohio State University",
          "University of Colorado Boulder",
          "University of Bristol",
          "University of California, Santa Cruz",
          "Yeshiva University",
          "University of Sydney",
          "University of Virginia",
          "University of Adelaide",
          "University of Southern California",
          "William & Mary",
          "Trinity College Dublin",
          "King’s College London",
          "Stony Brook University",
          "Korea Advanced Institute of Science and Technology (KAIST)",
          "University of Sussex",
          "The University of Queensland",
          "University of York",
          "Heidelberg University",
          "University of Utah",
          "Durham University",
          "London School of Economics and Political Science",
          "University of Manchester",
          "Royal Holloway, University of London",
          "Lund University",
          "University of Southampton",
          "University of Zurich",
          "Wake Forest University",
          "McMaster University",
          "University College Dublin",
          "George Washington University",
          "University of Arizona",
          "University of Basel",
          "University of Maryland, College Park",
          "Dartmouth College",
          "École Normale Supérieure de Lyon"
         ],
         "type": "scatter",
         "x": [
          "1",
          "2",
          "3",
          "4",
          "5",
          "6",
          "6",
          "8",
          "9",
          "10",
          "11",
          "12",
          "13",
          "14",
          "15",
          "15",
          "17",
          "18",
          "19",
          "20",
          "21",
          "22",
          "23",
          "24",
          "25",
          "26",
          "27",
          "28",
          "29",
          "30",
          "30",
          "32",
          "33",
          "34",
          "35",
          "36",
          "37",
          "38",
          "39",
          "40",
          "41",
          "42",
          "43",
          "43",
          "43",
          "43",
          "47",
          "48",
          "49",
          "49",
          "51",
          "52",
          "53",
          "54",
          "55",
          "56",
          "57",
          "58",
          "59",
          "60",
          "61",
          "61",
          "63",
          "64",
          "65",
          "66",
          "67",
          "68",
          "68",
          "68",
          "71",
          "72",
          "73",
          "73",
          "75",
          "76",
          "77",
          "78",
          "79",
          "79",
          "81",
          "81",
          "83",
          "83",
          "85",
          "86",
          "87",
          "88",
          "89",
          "90",
          "90",
          "90",
          "93",
          "94",
          "95",
          "95",
          "95",
          "98",
          "99",
          "100"
         ],
         "y": [
          99.7,
          97.7,
          97.8,
          98.3,
          90.9,
          90.5,
          88.2,
          84.2,
          89.2,
          92.1,
          83,
          79.1,
          80.9,
          82.2,
          77.5,
          83.9,
          75.8,
          73.8,
          71.8,
          70.3,
          68.4,
          74,
          68.2,
          66.8,
          64.5,
          87.7,
          67.9,
          69.5,
          56.6,
          65.1,
          70.9,
          59.8,
          68.1,
          65.5,
          69,
          58.7,
          76.4,
          58.9,
          57.9,
          59.9,
          50.4,
          66.8,
          51.9,
          65.8,
          57.3,
          55.5,
          57.4,
          55,
          49.4,
          57.5,
          64.9,
          57.6,
          64.1,
          57.3,
          59.7,
          61.3,
          78.9,
          74.9,
          53.6,
          62,
          63.4,
          59.1,
          56.4,
          58.5,
          67.2,
          63.5,
          46.4,
          49.6,
          38.3,
          63.5,
          49.8,
          62,
          46.5,
          65.4,
          53.1,
          47.7,
          48.5,
          48.5,
          71.3,
          42.4,
          51.8,
          47.9,
          59.2,
          55.8,
          39.8,
          62.4,
          56.5,
          37.7,
          46.3,
          50.8,
          56.6,
          54.6,
          44.7,
          42.4,
          60.6,
          52.4,
          50.2,
          45.4,
          44.7,
          51.1
         ]
        }
       ],
       "layout": {
        "template": {
         "data": {
          "bar": [
           {
            "error_x": {
             "color": "#2a3f5f"
            },
            "error_y": {
             "color": "#2a3f5f"
            },
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "bar"
           }
          ],
          "barpolar": [
           {
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "barpolar"
           }
          ],
          "carpet": [
           {
            "aaxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "baxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "type": "carpet"
           }
          ],
          "choropleth": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "choropleth"
           }
          ],
          "contour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "contour"
           }
          ],
          "contourcarpet": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "contourcarpet"
           }
          ],
          "heatmap": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmap"
           }
          ],
          "heatmapgl": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmapgl"
           }
          ],
          "histogram": [
           {
            "marker": {
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "histogram"
           }
          ],
          "histogram2d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2d"
           }
          ],
          "histogram2dcontour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2dcontour"
           }
          ],
          "mesh3d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "mesh3d"
           }
          ],
          "parcoords": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "parcoords"
           }
          ],
          "pie": [
           {
            "automargin": true,
            "type": "pie"
           }
          ],
          "scatter": [
           {
            "fillpattern": {
             "fillmode": "overlay",
             "size": 10,
             "solidity": 0.2
            },
            "type": "scatter"
           }
          ],
          "scatter3d": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatter3d"
           }
          ],
          "scattercarpet": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattercarpet"
           }
          ],
          "scattergeo": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergeo"
           }
          ],
          "scattergl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergl"
           }
          ],
          "scattermapbox": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattermapbox"
           }
          ],
          "scatterpolar": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolar"
           }
          ],
          "scatterpolargl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolargl"
           }
          ],
          "scatterternary": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterternary"
           }
          ],
          "surface": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "surface"
           }
          ],
          "table": [
           {
            "cells": {
             "fill": {
              "color": "#EBF0F8"
             },
             "line": {
              "color": "white"
             }
            },
            "header": {
             "fill": {
              "color": "#C8D4E3"
             },
             "line": {
              "color": "white"
             }
            },
            "type": "table"
           }
          ]
         },
         "layout": {
          "annotationdefaults": {
           "arrowcolor": "#2a3f5f",
           "arrowhead": 0,
           "arrowwidth": 1
          },
          "autotypenumbers": "strict",
          "coloraxis": {
           "colorbar": {
            "outlinewidth": 0,
            "ticks": ""
           }
          },
          "colorscale": {
           "diverging": [
            [
             0,
             "#8e0152"
            ],
            [
             0.1,
             "#c51b7d"
            ],
            [
             0.2,
             "#de77ae"
            ],
            [
             0.3,
             "#f1b6da"
            ],
            [
             0.4,
             "#fde0ef"
            ],
            [
             0.5,
             "#f7f7f7"
            ],
            [
             0.6,
             "#e6f5d0"
            ],
            [
             0.7,
             "#b8e186"
            ],
            [
             0.8,
             "#7fbc41"
            ],
            [
             0.9,
             "#4d9221"
            ],
            [
             1,
             "#276419"
            ]
           ],
           "sequential": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ],
           "sequentialminus": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ]
          },
          "colorway": [
           "#636efa",
           "#EF553B",
           "#00cc96",
           "#ab63fa",
           "#FFA15A",
           "#19d3f3",
           "#FF6692",
           "#B6E880",
           "#FF97FF",
           "#FECB52"
          ],
          "font": {
           "color": "#2a3f5f"
          },
          "geo": {
           "bgcolor": "white",
           "lakecolor": "white",
           "landcolor": "#E5ECF6",
           "showlakes": true,
           "showland": true,
           "subunitcolor": "white"
          },
          "hoverlabel": {
           "align": "left"
          },
          "hovermode": "closest",
          "mapbox": {
           "style": "light"
          },
          "paper_bgcolor": "white",
          "plot_bgcolor": "#E5ECF6",
          "polar": {
           "angularaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "radialaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "scene": {
           "xaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "yaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "zaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           }
          },
          "shapedefaults": {
           "line": {
            "color": "#2a3f5f"
           }
          },
          "ternary": {
           "aaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "baxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "caxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "title": {
           "x": 0.05
          },
          "xaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          },
          "yaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          }
         }
        },
        "title": {
         "text": "Citation and Teaching vs World Rank of Top 100 Universities"
        },
        "xaxis": {
         "ticklen": 5,
         "title": {
          "text": "World Rank"
         },
         "zeroline": false
        }
       }
      },
      "text/html": [
       "<div>                            <div id=\"d74f4706-7963-4c0f-bc70-2d0b232e37a4\" class=\"plotly-graph-div\" style=\"height:525px; width:100%;\"></div>            <script type=\"text/javascript\">                require([\"plotly\"], function(Plotly) {                    window.PLOTLYENV=window.PLOTLYENV || {};                                    if (document.getElementById(\"d74f4706-7963-4c0f-bc70-2d0b232e37a4\")) {                    Plotly.newPlot(                        \"d74f4706-7963-4c0f-bc70-2d0b232e37a4\",                        [{\"marker\":{\"color\":\"rgba(16, 112, 2, 0.8)\"},\"mode\":\"lines\",\"name\":\"citations\",\"text\":[\"Harvard University\",\"California Institute of Technology\",\"Massachusetts Institute of Technology\",\"Stanford University\",\"Princeton University\",\"University of Cambridge\",\"University of Oxford\",\"University of California, Berkeley\",\"Imperial College London\",\"Yale University\",\"University of California, Los Angeles\",\"University of Chicago\",\"Johns Hopkins University\",\"Cornell University\",\"ETH Zurich \\u2013 Swiss Federal Institute of Technology Zurich\",\"University of Michigan\",\"University of Toronto\",\"Columbia University\",\"University of Pennsylvania\",\"Carnegie Mellon University\",\"University of Hong Kong\",\"University College London\",\"University of Washington\",\"Duke University\",\"Northwestern University\",\"University of Tokyo\",\"Georgia Institute of Technology\",\"Pohang University of Science and Technology\",\"University of California, Santa Barbara\",\"University of British Columbia\",\"University of North Carolina at Chapel Hill\",\"University of California, San Diego\",\"University of Illinois at Urbana-Champaign\",\"National University of Singapore\",\"McGill University\",\"University of Melbourne\",\"Peking University\",\"Washington University in St Louis\",\"\\u00c9cole Polytechnique\",\"University of Edinburgh\",\"Hong Kong University of Science and Technology\",\"\\u00c9cole Normale Sup\\u00e9rieure\",\"Australian National University\",\"Karolinska Institute\",\"University of G\\u00f6ttingen\",\"University of Wisconsin\",\"Rice University\",\"\\u00c9cole Polytechnique F\\u00e9d\\u00e9rale de Lausanne\",\"University of California, Irvine\",\"University of Science and Technology of China\",\"Vanderbilt University\",\"University of Minnesota\",\"Tufts University\",\"University of California, Davis\",\"Brown University\",\"University of Massachusetts\",\"Kyoto University\",\"Tsinghua University\",\"Boston University\",\"New York University\",\"Emory University\",\"LMU Munich\",\"University of Notre Dame\",\"University of Pittsburgh\",\"Case Western Reserve University\",\"Ohio State University\",\"University of Colorado Boulder\",\"University of Bristol\",\"University of California, Santa Cruz\",\"Yeshiva University\",\"University of Sydney\",\"University of Virginia\",\"University of Adelaide\",\"University of Southern California\",\"William & Mary\",\"Trinity College Dublin\",\"King\\u2019s College London\",\"Stony Brook University\",\"Korea Advanced Institute of Science and Technology (KAIST)\",\"University of Sussex\",\"The University of Queensland\",\"University of York\",\"Heidelberg University\",\"University of Utah\",\"Durham University\",\"London School of Economics and Political Science\",\"University of Manchester\",\"Royal Holloway, University of London\",\"Lund University\",\"University of Southampton\",\"University of Zurich\",\"Wake Forest University\",\"McMaster University\",\"University College Dublin\",\"George Washington University\",\"University of Arizona\",\"University of Basel\",\"University of Maryland, College Park\",\"Dartmouth College\",\"\\u00c9cole Normale Sup\\u00e9rieure de Lyon\"],\"x\":[\"1\",\"2\",\"3\",\"4\",\"5\",\"6\",\"6\",\"8\",\"9\",\"10\",\"11\",\"12\",\"13\",\"14\",\"15\",\"15\",\"17\",\"18\",\"19\",\"20\",\"21\",\"22\",\"23\",\"24\",\"25\",\"26\",\"27\",\"28\",\"29\",\"30\",\"30\",\"32\",\"33\",\"34\",\"35\",\"36\",\"37\",\"38\",\"39\",\"40\",\"41\",\"42\",\"43\",\"43\",\"43\",\"43\",\"47\",\"48\",\"49\",\"49\",\"51\",\"52\",\"53\",\"54\",\"55\",\"56\",\"57\",\"58\",\"59\",\"60\",\"61\",\"61\",\"63\",\"64\",\"65\",\"66\",\"67\",\"68\",\"68\",\"68\",\"71\",\"72\",\"73\",\"73\",\"75\",\"76\",\"77\",\"78\",\"79\",\"79\",\"81\",\"81\",\"83\",\"83\",\"85\",\"86\",\"87\",\"88\",\"89\",\"90\",\"90\",\"90\",\"93\",\"94\",\"95\",\"95\",\"95\",\"98\",\"99\",\"100\"],\"y\":[98.8,99.9,99.9,99.2,99.9,94.0,95.1,97.8,88.3,91.5,93.2,96.9,92.3,88.1,83.1,84.1,82.2,92.6,93.6,95.7,96.1,80.6,95.9,92.3,95.3,58.1,83.2,96.5,98.8,80.3,85.0,90.8,72.9,78.7,69.0,83.3,72.2,88.6,91.4,86.8,98.2,95.7,81.0,62.3,92.5,83.4,99.1,83.8,91.6,92.7,78.1,76.4,83.9,68.8,77.7,67.9,46.3,52.7,91.4,82.9,77.8,76.4,89.1,78.3,66.0,67.2,83.4,80.9,99.6,74.4,64.3,68.6,90.5,71.9,95.6,84.4,72.1,85.8,45.5,91.6,69.0,81.9,70.3,72.0,91.0,51.6,59.2,93.2,67.6,72.9,65.0,79.2,68.5,86.3,70.2,70.1,78.3,79.2,79.7,88.8],\"type\":\"scatter\"},{\"marker\":{\"color\":\"rgba(80, 26, 80, 0.8)\"},\"mode\":\"lines+markers\",\"name\":\"teaching\",\"text\":[\"Harvard University\",\"California Institute of Technology\",\"Massachusetts Institute of Technology\",\"Stanford University\",\"Princeton University\",\"University of Cambridge\",\"University of Oxford\",\"University of California, Berkeley\",\"Imperial College London\",\"Yale University\",\"University of California, Los Angeles\",\"University of Chicago\",\"Johns Hopkins University\",\"Cornell University\",\"ETH Zurich \\u2013 Swiss Federal Institute of Technology Zurich\",\"University of Michigan\",\"University of Toronto\",\"Columbia University\",\"University of Pennsylvania\",\"Carnegie Mellon University\",\"University of Hong Kong\",\"University College London\",\"University of Washington\",\"Duke University\",\"Northwestern University\",\"University of Tokyo\",\"Georgia Institute of Technology\",\"Pohang University of Science and Technology\",\"University of California, Santa Barbara\",\"University of British Columbia\",\"University of North Carolina at Chapel Hill\",\"University of California, San Diego\",\"University of Illinois at Urbana-Champaign\",\"National University of Singapore\",\"McGill University\",\"University of Melbourne\",\"Peking University\",\"Washington University in St Louis\",\"\\u00c9cole Polytechnique\",\"University of Edinburgh\",\"Hong Kong University of Science and Technology\",\"\\u00c9cole Normale Sup\\u00e9rieure\",\"Australian National University\",\"Karolinska Institute\",\"University of G\\u00f6ttingen\",\"University of Wisconsin\",\"Rice University\",\"\\u00c9cole Polytechnique F\\u00e9d\\u00e9rale de Lausanne\",\"University of California, Irvine\",\"University of Science and Technology of China\",\"Vanderbilt University\",\"University of Minnesota\",\"Tufts University\",\"University of California, Davis\",\"Brown University\",\"University of Massachusetts\",\"Kyoto University\",\"Tsinghua University\",\"Boston University\",\"New York University\",\"Emory University\",\"LMU Munich\",\"University of Notre Dame\",\"University of Pittsburgh\",\"Case Western Reserve University\",\"Ohio State University\",\"University of Colorado Boulder\",\"University of Bristol\",\"University of California, Santa Cruz\",\"Yeshiva University\",\"University of Sydney\",\"University of Virginia\",\"University of Adelaide\",\"University of Southern California\",\"William & Mary\",\"Trinity College Dublin\",\"King\\u2019s College London\",\"Stony Brook University\",\"Korea Advanced Institute of Science and Technology (KAIST)\",\"University of Sussex\",\"The University of Queensland\",\"University of York\",\"Heidelberg University\",\"University of Utah\",\"Durham University\",\"London School of Economics and Political Science\",\"University of Manchester\",\"Royal Holloway, University of London\",\"Lund University\",\"University of Southampton\",\"University of Zurich\",\"Wake Forest University\",\"McMaster University\",\"University College Dublin\",\"George Washington University\",\"University of Arizona\",\"University of Basel\",\"University of Maryland, College Park\",\"Dartmouth College\",\"\\u00c9cole Normale Sup\\u00e9rieure de Lyon\"],\"x\":[\"1\",\"2\",\"3\",\"4\",\"5\",\"6\",\"6\",\"8\",\"9\",\"10\",\"11\",\"12\",\"13\",\"14\",\"15\",\"15\",\"17\",\"18\",\"19\",\"20\",\"21\",\"22\",\"23\",\"24\",\"25\",\"26\",\"27\",\"28\",\"29\",\"30\",\"30\",\"32\",\"33\",\"34\",\"35\",\"36\",\"37\",\"38\",\"39\",\"40\",\"41\",\"42\",\"43\",\"43\",\"43\",\"43\",\"47\",\"48\",\"49\",\"49\",\"51\",\"52\",\"53\",\"54\",\"55\",\"56\",\"57\",\"58\",\"59\",\"60\",\"61\",\"61\",\"63\",\"64\",\"65\",\"66\",\"67\",\"68\",\"68\",\"68\",\"71\",\"72\",\"73\",\"73\",\"75\",\"76\",\"77\",\"78\",\"79\",\"79\",\"81\",\"81\",\"83\",\"83\",\"85\",\"86\",\"87\",\"88\",\"89\",\"90\",\"90\",\"90\",\"93\",\"94\",\"95\",\"95\",\"95\",\"98\",\"99\",\"100\"],\"y\":[99.7,97.7,97.8,98.3,90.9,90.5,88.2,84.2,89.2,92.1,83.0,79.1,80.9,82.2,77.5,83.9,75.8,73.8,71.8,70.3,68.4,74.0,68.2,66.8,64.5,87.7,67.9,69.5,56.6,65.1,70.9,59.8,68.1,65.5,69.0,58.7,76.4,58.9,57.9,59.9,50.4,66.8,51.9,65.8,57.3,55.5,57.4,55.0,49.4,57.5,64.9,57.6,64.1,57.3,59.7,61.3,78.9,74.9,53.6,62.0,63.4,59.1,56.4,58.5,67.2,63.5,46.4,49.6,38.3,63.5,49.8,62.0,46.5,65.4,53.1,47.7,48.5,48.5,71.3,42.4,51.8,47.9,59.2,55.8,39.8,62.4,56.5,37.7,46.3,50.8,56.6,54.6,44.7,42.4,60.6,52.4,50.2,45.4,44.7,51.1],\"type\":\"scatter\"}],                        {\"template\":{\"data\":{\"barpolar\":[{\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"barpolar\"}],\"bar\":[{\"error_x\":{\"color\":\"#2a3f5f\"},\"error_y\":{\"color\":\"#2a3f5f\"},\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"bar\"}],\"carpet\":[{\"aaxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"baxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"type\":\"carpet\"}],\"choropleth\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"choropleth\"}],\"contourcarpet\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"contourcarpet\"}],\"contour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"contour\"}],\"heatmapgl\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmapgl\"}],\"heatmap\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmap\"}],\"histogram2dcontour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2dcontour\"}],\"histogram2d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2d\"}],\"histogram\":[{\"marker\":{\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"histogram\"}],\"mesh3d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"mesh3d\"}],\"parcoords\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"parcoords\"}],\"pie\":[{\"automargin\":true,\"type\":\"pie\"}],\"scatter3d\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatter3d\"}],\"scattercarpet\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattercarpet\"}],\"scattergeo\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergeo\"}],\"scattergl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergl\"}],\"scattermapbox\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattermapbox\"}],\"scatterpolargl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolargl\"}],\"scatterpolar\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolar\"}],\"scatter\":[{\"fillpattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2},\"type\":\"scatter\"}],\"scatterternary\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterternary\"}],\"surface\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"surface\"}],\"table\":[{\"cells\":{\"fill\":{\"color\":\"#EBF0F8\"},\"line\":{\"color\":\"white\"}},\"header\":{\"fill\":{\"color\":\"#C8D4E3\"},\"line\":{\"color\":\"white\"}},\"type\":\"table\"}]},\"layout\":{\"annotationdefaults\":{\"arrowcolor\":\"#2a3f5f\",\"arrowhead\":0,\"arrowwidth\":1},\"autotypenumbers\":\"strict\",\"coloraxis\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"colorscale\":{\"diverging\":[[0,\"#8e0152\"],[0.1,\"#c51b7d\"],[0.2,\"#de77ae\"],[0.3,\"#f1b6da\"],[0.4,\"#fde0ef\"],[0.5,\"#f7f7f7\"],[0.6,\"#e6f5d0\"],[0.7,\"#b8e186\"],[0.8,\"#7fbc41\"],[0.9,\"#4d9221\"],[1,\"#276419\"]],\"sequential\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"sequentialminus\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]]},\"colorway\":[\"#636efa\",\"#EF553B\",\"#00cc96\",\"#ab63fa\",\"#FFA15A\",\"#19d3f3\",\"#FF6692\",\"#B6E880\",\"#FF97FF\",\"#FECB52\"],\"font\":{\"color\":\"#2a3f5f\"},\"geo\":{\"bgcolor\":\"white\",\"lakecolor\":\"white\",\"landcolor\":\"#E5ECF6\",\"showlakes\":true,\"showland\":true,\"subunitcolor\":\"white\"},\"hoverlabel\":{\"align\":\"left\"},\"hovermode\":\"closest\",\"mapbox\":{\"style\":\"light\"},\"paper_bgcolor\":\"white\",\"plot_bgcolor\":\"#E5ECF6\",\"polar\":{\"angularaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"radialaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"scene\":{\"xaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"yaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"zaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"}},\"shapedefaults\":{\"line\":{\"color\":\"#2a3f5f\"}},\"ternary\":{\"aaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"baxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"caxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"title\":{\"x\":0.05},\"xaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2},\"yaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2}}},\"title\":{\"text\":\"Citation and Teaching vs World Rank of Top 100 Universities\"},\"xaxis\":{\"ticklen\":5,\"title\":{\"text\":\"World Rank\"},\"zeroline\":false}},                        {\"responsive\": true}                    ).then(function(){\n",
       "                            \n",
       "var gd = document.getElementById('d74f4706-7963-4c0f-bc70-2d0b232e37a4');\n",
       "var x = new MutationObserver(function (mutations, observer) {{\n",
       "        var display = window.getComputedStyle(gd).display;\n",
       "        if (!display || display === 'none') {{\n",
       "            console.log([gd, 'removed!']);\n",
       "            Plotly.purge(gd);\n",
       "            observer.disconnect();\n",
       "        }}\n",
       "}});\n",
       "\n",
       "// Listen for the removal of the full notebook cells\n",
       "var notebookContainer = gd.closest('#notebook-container');\n",
       "if (notebookContainer) {{\n",
       "    x.observe(notebookContainer, {childList: true});\n",
       "}}\n",
       "\n",
       "// Listen for the clearing of the current output cell\n",
       "var outputEl = gd.closest('.output');\n",
       "if (outputEl) {{\n",
       "    x.observe(outputEl, {childList: true});\n",
       "}}\n",
       "\n",
       "                        })                };                });            </script>        </div>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "# prepare data frame\n",
    "df = timesData.iloc[:100,:]\n",
    "\n",
    "# import graph objects as \"go\"\n",
    "import plotly.graph_objs as go\n",
    "\n",
    "# Creating trace1\n",
    "trace1 = go.Scatter(\n",
    "                    x = df.world_rank,\n",
    "                    y = df.citations,\n",
    "                    mode = \"lines\",\n",
    "                    name = \"citations\",\n",
    "                    marker = dict(color = 'rgba(16, 112, 2, 0.8)'),\n",
    "                    text= df.university_name)\n",
    "# Creating trace2\n",
    "trace2 = go.Scatter(\n",
    "                    x = df.world_rank,\n",
    "                    y = df.teaching,\n",
    "                    mode = \"lines+markers\",\n",
    "                    name = \"teaching\",\n",
    "                    marker = dict(color = 'rgba(80, 26, 80, 0.8)'),\n",
    "                    text= df.university_name)\n",
    "data = [trace1, trace2]\n",
    "layout = dict(title = 'Citation and Teaching vs World Rank of Top 100 Universities',\n",
    "              xaxis= dict(title= 'World Rank',ticklen= 5,zeroline= False)\n",
    "             )\n",
    "fig = dict(data = data, layout = layout)\n",
    "iplot(fig)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.plotly.v1+json": {
       "config": {
        "linkText": "Export to plot.ly",
        "plotlyServerURL": "https://plot.ly",
        "showLink": false
       },
       "data": [
        {
         "marker": {
          "color": "rgba(255, 128, 255, 0.8)"
         },
         "mode": "markers",
         "name": "2014",
         "text": [
          "California Institute of Technology",
          "Harvard University",
          "University of Oxford",
          "Stanford University",
          "Massachusetts Institute of Technology",
          "Princeton University",
          "University of Cambridge",
          "University of California, Berkeley",
          "University of Chicago",
          "Imperial College London",
          "Yale University",
          "University of California, Los Angeles",
          "Columbia University",
          "ETH Zurich – Swiss Federal Institute of Technology Zurich",
          "Johns Hopkins University",
          "University of Pennsylvania",
          "Duke University",
          "University of Michigan",
          "Cornell University",
          "University of Toronto",
          "University College London",
          "Northwestern University",
          "University of Tokyo",
          "Carnegie Mellon University",
          "University of Washington",
          "National University of Singapore",
          "University of Texas at Austin",
          "Georgia Institute of Technology",
          "University of Illinois at Urbana-Champaign",
          "University of Wisconsin-Madison",
          "University of British Columbia",
          "London School of Economics and Political Science",
          "University of California, Santa Barbara",
          "University of Melbourne",
          "McGill University",
          "Karolinska Institute",
          "École Polytechnique Fédérale de Lausanne",
          "King’s College London",
          "University of Edinburgh",
          "New York University",
          "University of California, San Diego",
          "Washington University in St Louis",
          "University of Hong Kong",
          "Seoul National University",
          "Peking University",
          "University of Minnesota",
          "University of North Carolina at Chapel Hill",
          "Australian National University",
          "Pennsylvania State University",
          "Boston University",
          "Tsinghua University",
          "Brown University",
          "Kyoto University",
          "University of California, Davis",
          "LMU Munich",
          "Korea Advanced Institute of Science and Technology (KAIST)",
          "Hong Kong University of Science and Technology",
          "University of Manchester",
          "Ohio State University",
          "Pohang University of Science and Technology",
          "KU Leuven",
          "Purdue University",
          "The University of Queensland",
          "University of Göttingen",
          "Rice University",
          "École Normale Supérieure",
          "Leiden University",
          "Heidelberg University",
          "Delft University of Technology",
          "University of Southern California",
          "École Polytechnique",
          "University of Sydney",
          "Erasmus University Rotterdam",
          "University of Basel",
          "Utrecht University",
          "Nanyang Technological University",
          "Wageningen University and Research Center",
          "University of Pittsburgh",
          "University of Bristol",
          "Durham University",
          "Emory University",
          "Tufts University",
          "Michigan State University",
          "University of Amsterdam",
          "Ghent University",
          "Free University of Berlin",
          "Technical University of Munich",
          "Case Western Reserve University",
          "Vanderbilt University",
          "University of Notre Dame",
          "Monash University",
          "McMaster University",
          "University of California, Irvine",
          "Humboldt University of Berlin",
          "University of Rochester",
          "Pierre and Marie Curie University",
          "University of Colorado Boulder",
          "Maastricht University",
          "University of Groningen",
          "University of Helsinki"
         ],
         "type": "scatter",
         "x": [
          "1",
          "2",
          "2",
          "4",
          "5",
          "6",
          "7",
          "8",
          "9",
          "10",
          "11",
          "12",
          "13",
          "14",
          "15",
          "16",
          "17",
          "18",
          "19",
          "20",
          "21",
          "22",
          "23",
          "24",
          "25",
          "26",
          "27",
          "28",
          "29",
          "30",
          "31",
          "32",
          "33",
          "34",
          "35",
          "36",
          "37",
          "38",
          "39",
          "40",
          "40",
          "42",
          "43",
          "44",
          "45",
          "46",
          "47",
          "48",
          "49",
          "50",
          "50",
          "52",
          "52",
          "52",
          "55",
          "56",
          "57",
          "58",
          "59",
          "60",
          "61",
          "62",
          "63",
          "63",
          "65",
          "65",
          "67",
          "68",
          "69",
          "70",
          "70",
          "72",
          "73",
          "74",
          "74",
          "76",
          "77",
          "78",
          "79",
          "80",
          "80",
          "80",
          "83",
          "83",
          "85",
          "86",
          "87",
          "88",
          "88",
          "90",
          "91",
          "92",
          "93",
          "94",
          "95",
          "96",
          "97",
          "98",
          "98",
          "100"
         ],
         "y": [
          99.8,
          99.1,
          95.4,
          99.1,
          100,
          99.7,
          95.7,
          99.3,
          98,
          90,
          93.5,
          95.6,
          95.6,
          85,
          95,
          95,
          96.7,
          90.8,
          90.8,
          84.5,
          84.1,
          97.1,
          69.8,
          93.9,
          95.6,
          66.4,
          91.3,
          87.9,
          79.4,
          87.2,
          83.7,
          69.2,
          99.4,
          80.2,
          74.5,
          76,
          95.9,
          87.6,
          87.6,
          87.9,
          96.7,
          96.4,
          61.5,
          47.3,
          62.8,
          81.2,
          90.2,
          71.2,
          79.4,
          95.3,
          59.9,
          91.3,
          58.2,
          81.2,
          83.3,
          67,
          72.3,
          77.3,
          79.4,
          85.7,
          72.9,
          67,
          73.3,
          89.6,
          99.9,
          87,
          84.2,
          76,
          47.2,
          81.2,
          82.3,
          66.6,
          81.2,
          81.4,
          82,
          67.5,
          74.1,
          84.4,
          84.9,
          88.2,
          90.8,
          93.9,
          71.5,
          75,
          74.9,
          64.8,
          80.7,
          82.8,
          86.5,
          91.8,
          65.4,
          79.4,
          89.7,
          68.4,
          89.7,
          82.3,
          97.3,
          65.8,
          71.1,
          77.8
         ]
        },
        {
         "marker": {
          "color": "rgba(255, 128, 2, 0.8)"
         },
         "mode": "markers",
         "name": "2015",
         "text": [
          "California Institute of Technology",
          "Harvard University",
          "University of Oxford",
          "Stanford University",
          "University of Cambridge",
          "Massachusetts Institute of Technology",
          "Princeton University",
          "University of California, Berkeley",
          "Imperial College London",
          "Yale University",
          "University of Chicago",
          "University of California, Los Angeles",
          "ETH Zurich – Swiss Federal Institute of Technology Zurich",
          "Columbia University",
          "Johns Hopkins University",
          "University of Pennsylvania",
          "University of Michigan",
          "Duke University",
          "Cornell University",
          "University of Toronto",
          "Northwestern University",
          "University College London",
          "University of Tokyo",
          "Carnegie Mellon University",
          "National University of Singapore",
          "University of Washington",
          "Georgia Institute of Technology",
          "University of Texas at Austin",
          "LMU Munich",
          "University of Illinois at Urbana-Champaign",
          "University of Wisconsin-Madison",
          "University of British Columbia",
          "University of Melbourne",
          "London School of Economics and Political Science",
          "École Polytechnique Fédérale de Lausanne",
          "University of Edinburgh",
          "University of California, Santa Barbara",
          "New York University",
          "McGill University",
          "King’s College London",
          "University of California, San Diego",
          "Washington University in St Louis",
          "University of Hong Kong",
          "Karolinska Institute",
          "Australian National University",
          "University of Minnesota",
          "University of North Carolina at Chapel Hill",
          "Peking University",
          "Tsinghua University",
          "Seoul National University",
          "Hong Kong University of Science and Technology",
          "Korea Advanced Institute of Science and Technology (KAIST)",
          "University of Manchester",
          "Brown University",
          "KU Leuven",
          "University of California, Davis",
          "Boston University",
          "Pennsylvania State University",
          "Kyoto University",
          "University of Sydney",
          "Nanyang Technological University",
          "École Polytechnique",
          "Scuola Normale Superiore di Pisa",
          "Leiden University",
          "The University of Queensland",
          "Pohang University of Science and Technology",
          "University of Göttingen",
          "Ohio State University",
          "Rice University",
          "Heidelberg University",
          "Delft University of Technology",
          "Erasmus University Rotterdam",
          "Wageningen University and Research Center",
          "University of Bristol",
          "University of Basel",
          "University of Southern California",
          "University of Amsterdam",
          "École Normale Supérieure",
          "Utrecht University",
          "Humboldt University of Berlin",
          "Free University of Berlin",
          "Michigan State University",
          "Durham University",
          "Monash University",
          "Middle East Technical University",
          "University of Arizona",
          "University of Notre Dame",
          "Tufts University",
          "University of California, Irvine",
          "Ghent University",
          "University of Massachusetts",
          "University of Pittsburgh",
          "Emory University",
          "McMaster University",
          "University of Glasgow",
          "Vanderbilt University",
          "University of Colorado Boulder",
          "Stockholm University",
          "Technical University of Munich",
          "Uppsala University"
         ],
         "type": "scatter",
         "x": [
          "1",
          "2",
          "3",
          "4",
          "5",
          "6",
          "7",
          "8",
          "9",
          "9",
          "11",
          "12",
          "13",
          "14",
          "15",
          "16",
          "17",
          "18",
          "19",
          "20",
          "21",
          "22",
          "23",
          "24",
          "25",
          "26",
          "27",
          "28",
          "29",
          "29",
          "29",
          "32",
          "33",
          "34",
          "34",
          "36",
          "37",
          "38",
          "39",
          "40",
          "41",
          "42",
          "43",
          "44",
          "45",
          "46",
          "46",
          "48",
          "49",
          "50",
          "51",
          "52",
          "52",
          "54",
          "55",
          "55",
          "57",
          "58",
          "59",
          "60",
          "61",
          "61",
          "63",
          "64",
          "65",
          "66",
          "67",
          "68",
          "69",
          "70",
          "71",
          "72",
          "73",
          "74",
          "75",
          "75",
          "77",
          "78",
          "79",
          "80",
          "81",
          "82",
          "83",
          "83",
          "85",
          "86",
          "86",
          "88",
          "88",
          "90",
          "91",
          "91",
          "93",
          "94",
          "94",
          "96",
          "97",
          "98",
          "98",
          "98"
         ],
         "y": [
          99.7,
          98.9,
          95.5,
          99.1,
          95.2,
          100,
          99.6,
          99.1,
          89.4,
          94,
          97.3,
          95.3,
          83.5,
          95.3,
          93.6,
          94.4,
          88.9,
          96.6,
          91.5,
          83,
          96.9,
          85.1,
          74.7,
          92,
          66,
          95,
          85.8,
          91.5,
          83,
          77.8,
          87.7,
          85.3,
          80.6,
          71.3,
          95,
          88.3,
          99.2,
          89.5,
          76,
          88.3,
          96.4,
          97.1,
          65.1,
          76.8,
          71.1,
          82.9,
          91,
          63.7,
          65,
          48.7,
          72.9,
          71.4,
          74.3,
          92,
          71.8,
          80.4,
          94.4,
          76,
          57,
          69,
          75.9,
          79.9,
          96.4,
          82.3,
          74.2,
          84.4,
          92.3,
          80.4,
          99.9,
          81.4,
          42.6,
          82.3,
          77.5,
          85.1,
          81.4,
          81.3,
          76.6,
          84.8,
          80,
          71.9,
          67.6,
          74,
          88.9,
          65.7,
          92,
          74,
          90,
          92.9,
          89.5,
          73.8,
          78.7,
          84.4,
          89.5,
          78.8,
          83.7,
          87.7,
          97.4,
          90.9,
          78.8,
          70.9
         ]
        },
        {
         "marker": {
          "color": "rgba(0, 255, 200, 0.8)"
         },
         "mode": "markers",
         "name": "2016",
         "text": [
          "California Institute of Technology",
          "University of Oxford",
          "Stanford University",
          "University of Cambridge",
          "Massachusetts Institute of Technology",
          "Harvard University",
          "Princeton University",
          "Imperial College London",
          "ETH Zurich – Swiss Federal Institute of Technology Zurich",
          "University of Chicago",
          "Johns Hopkins University",
          "Yale University",
          "University of California, Berkeley",
          "University College London",
          "Columbia University",
          "University of California, Los Angeles",
          "University of Pennsylvania",
          "Cornell University",
          "University of Toronto",
          "Duke University",
          "University of Michigan",
          "Carnegie Mellon University",
          "London School of Economics and Political Science",
          "University of Edinburgh",
          "Northwestern University",
          "National University of Singapore",
          "King’s College London",
          "Karolinska Institute",
          "LMU Munich",
          "New York University",
          "École Polytechnique Fédérale de Lausanne",
          "University of Washington",
          "University of Melbourne",
          "University of British Columbia",
          "KU Leuven",
          "University of Illinois at Urbana-Champaign",
          "Heidelberg University",
          "McGill University",
          "University of California, San Diego",
          "University of California, Santa Barbara",
          "Georgia Institute of Technology",
          "Peking University",
          "University of Tokyo",
          "University of California, Davis",
          "University of Hong Kong",
          "University of Texas at Austin",
          "Tsinghua University",
          "Wageningen University and Research Center",
          "Humboldt University of Berlin",
          "University of Wisconsin-Madison",
          "Brown University",
          "Australian National University",
          "Technical University of Munich",
          "École Normale Supérieure",
          "Nanyang Technological University",
          "University of Manchester",
          "University of Sydney",
          "University of Amsterdam",
          "Hong Kong University of Science and Technology",
          "The University of Queensland",
          "Washington University in St Louis",
          "Utrecht University",
          "University of North Carolina at Chapel Hill",
          "Boston University",
          "Delft University of Technology",
          "University of Minnesota",
          "Leiden University",
          "University of Southern California",
          "University of Bristol",
          "Durham University",
          "Erasmus University Rotterdam",
          "Free University of Berlin",
          "Monash University",
          "University of Groningen",
          "Pennsylvania State University",
          "University of Glasgow",
          "University of Helsinki",
          "University of Tübingen",
          "University of Pittsburgh",
          "University of Warwick",
          "Uppsala University",
          "University of Copenhagen",
          "University of New South Wales",
          "University of Freiburg",
          "Seoul National University",
          "University of St Andrews",
          "Vanderbilt University",
          "Kyoto University",
          "Maastricht University",
          "Emory University",
          "Lund University",
          "Ohio State University",
          "University of Exeter",
          "University of Bonn",
          "Georgetown University",
          "McMaster University",
          "University of Sheffield",
          "Queen Mary University of London",
          "University of Göttingen",
          "Michigan State University"
         ],
         "type": "scatter",
         "x": [
          "1",
          "2",
          "3",
          "4",
          "5",
          "6",
          "7",
          "8",
          "9",
          "10",
          "11",
          "12",
          "13",
          "14",
          "15",
          "16",
          "17",
          "18",
          "19",
          "20",
          "21",
          "22",
          "23",
          "24",
          "25",
          "26",
          "27",
          "28",
          "29",
          "30",
          "31",
          "32",
          "33",
          "34",
          "35",
          "36",
          "37",
          "38",
          "=39",
          "=39",
          "41",
          "42",
          "43",
          "=44",
          "=44",
          "46",
          "=47",
          "=47",
          "49",
          "50",
          "51",
          "52",
          "53",
          "54",
          "55",
          "=56",
          "=56",
          "58",
          "59",
          "=60",
          "=60",
          "62",
          "63",
          "64",
          "=65",
          "=65",
          "67",
          "68",
          "69",
          "70",
          "71",
          "72",
          "73",
          "74",
          "75",
          "=76",
          "=76",
          "78",
          "79",
          "80",
          "81",
          "=82",
          "=82",
          "84",
          "85",
          "86",
          "87",
          "=88",
          "=88",
          "=90",
          "=90",
          "=90",
          "93",
          "=94",
          "=94",
          "=94",
          "97",
          "98",
          "=99",
          "=99"
         ],
         "y": [
          99.8,
          98.8,
          99.9,
          97,
          99.7,
          99.8,
          99.3,
          96.7,
          91.1,
          99.2,
          98.2,
          97.2,
          99.7,
          94.2,
          98.1,
          98.5,
          98.6,
          97.2,
          90.9,
          99,
          94.4,
          99.1,
          94.3,
          96.3,
          96.5,
          79.4,
          93.8,
          92.2,
          85.7,
          95.3,
          94.6,
          98.6,
          86.6,
          91.5,
          87.3,
          86.8,
          88.2,
          78.9,
          98.7,
          99.2,
          86,
          69.1,
          60.9,
          84.3,
          70.1,
          92.2,
          58.8,
          87.8,
          73.6,
          86.6,
          96.4,
          72.3,
          80.1,
          87.1,
          85.6,
          77.3,
          77.5,
          87.4,
          82.6,
          82.4,
          99.2,
          88.1,
          95.9,
          97.7,
          61.5,
          88,
          85.2,
          93,
          91.2,
          87.7,
          95.6,
          60.2,
          73.3,
          84,
          80.5,
          92.3,
          82.1,
          79.3,
          92.3,
          78.2,
          80.9,
          86.2,
          82.1,
          80.5,
          50,
          78.8,
          95.7,
          46.6,
          82.7,
          96.7,
          81.3,
          83.2,
          94.3,
          85.3,
          82.5,
          84.9,
          80.1,
          93.3,
          72.7,
          76.8
         ]
        }
       ],
       "layout": {
        "template": {
         "data": {
          "bar": [
           {
            "error_x": {
             "color": "#2a3f5f"
            },
            "error_y": {
             "color": "#2a3f5f"
            },
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "bar"
           }
          ],
          "barpolar": [
           {
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "barpolar"
           }
          ],
          "carpet": [
           {
            "aaxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "baxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "type": "carpet"
           }
          ],
          "choropleth": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "choropleth"
           }
          ],
          "contour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "contour"
           }
          ],
          "contourcarpet": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "contourcarpet"
           }
          ],
          "heatmap": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmap"
           }
          ],
          "heatmapgl": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmapgl"
           }
          ],
          "histogram": [
           {
            "marker": {
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "histogram"
           }
          ],
          "histogram2d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2d"
           }
          ],
          "histogram2dcontour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2dcontour"
           }
          ],
          "mesh3d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "mesh3d"
           }
          ],
          "parcoords": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "parcoords"
           }
          ],
          "pie": [
           {
            "automargin": true,
            "type": "pie"
           }
          ],
          "scatter": [
           {
            "fillpattern": {
             "fillmode": "overlay",
             "size": 10,
             "solidity": 0.2
            },
            "type": "scatter"
           }
          ],
          "scatter3d": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatter3d"
           }
          ],
          "scattercarpet": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattercarpet"
           }
          ],
          "scattergeo": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergeo"
           }
          ],
          "scattergl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergl"
           }
          ],
          "scattermapbox": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattermapbox"
           }
          ],
          "scatterpolar": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolar"
           }
          ],
          "scatterpolargl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolargl"
           }
          ],
          "scatterternary": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterternary"
           }
          ],
          "surface": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "surface"
           }
          ],
          "table": [
           {
            "cells": {
             "fill": {
              "color": "#EBF0F8"
             },
             "line": {
              "color": "white"
             }
            },
            "header": {
             "fill": {
              "color": "#C8D4E3"
             },
             "line": {
              "color": "white"
             }
            },
            "type": "table"
           }
          ]
         },
         "layout": {
          "annotationdefaults": {
           "arrowcolor": "#2a3f5f",
           "arrowhead": 0,
           "arrowwidth": 1
          },
          "autotypenumbers": "strict",
          "coloraxis": {
           "colorbar": {
            "outlinewidth": 0,
            "ticks": ""
           }
          },
          "colorscale": {
           "diverging": [
            [
             0,
             "#8e0152"
            ],
            [
             0.1,
             "#c51b7d"
            ],
            [
             0.2,
             "#de77ae"
            ],
            [
             0.3,
             "#f1b6da"
            ],
            [
             0.4,
             "#fde0ef"
            ],
            [
             0.5,
             "#f7f7f7"
            ],
            [
             0.6,
             "#e6f5d0"
            ],
            [
             0.7,
             "#b8e186"
            ],
            [
             0.8,
             "#7fbc41"
            ],
            [
             0.9,
             "#4d9221"
            ],
            [
             1,
             "#276419"
            ]
           ],
           "sequential": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ],
           "sequentialminus": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ]
          },
          "colorway": [
           "#636efa",
           "#EF553B",
           "#00cc96",
           "#ab63fa",
           "#FFA15A",
           "#19d3f3",
           "#FF6692",
           "#B6E880",
           "#FF97FF",
           "#FECB52"
          ],
          "font": {
           "color": "#2a3f5f"
          },
          "geo": {
           "bgcolor": "white",
           "lakecolor": "white",
           "landcolor": "#E5ECF6",
           "showlakes": true,
           "showland": true,
           "subunitcolor": "white"
          },
          "hoverlabel": {
           "align": "left"
          },
          "hovermode": "closest",
          "mapbox": {
           "style": "light"
          },
          "paper_bgcolor": "white",
          "plot_bgcolor": "#E5ECF6",
          "polar": {
           "angularaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "radialaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "scene": {
           "xaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "yaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "zaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           }
          },
          "shapedefaults": {
           "line": {
            "color": "#2a3f5f"
           }
          },
          "ternary": {
           "aaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "baxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "caxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "title": {
           "x": 0.05
          },
          "xaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          },
          "yaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          }
         }
        },
        "title": {
         "text": "Citation vs world rank of top 100 universities with 2014, 2015 and 2016 years"
        },
        "xaxis": {
         "ticklen": 5,
         "title": {
          "text": "World Rank"
         },
         "zeroline": false
        },
        "yaxis": {
         "ticklen": 5,
         "title": {
          "text": "Citation"
         },
         "zeroline": false
        }
       }
      },
      "text/html": [
       "<div>                            <div id=\"e7f720f6-9559-453d-9182-adf198419126\" class=\"plotly-graph-div\" style=\"height:525px; width:100%;\"></div>            <script type=\"text/javascript\">                require([\"plotly\"], function(Plotly) {                    window.PLOTLYENV=window.PLOTLYENV || {};                                    if (document.getElementById(\"e7f720f6-9559-453d-9182-adf198419126\")) {                    Plotly.newPlot(                        \"e7f720f6-9559-453d-9182-adf198419126\",                        [{\"marker\":{\"color\":\"rgba(255, 128, 255, 0.8)\"},\"mode\":\"markers\",\"name\":\"2014\",\"text\":[\"California Institute of Technology\",\"Harvard University\",\"University of Oxford\",\"Stanford University\",\"Massachusetts Institute of Technology\",\"Princeton University\",\"University of Cambridge\",\"University of California, Berkeley\",\"University of Chicago\",\"Imperial College London\",\"Yale University\",\"University of California, Los Angeles\",\"Columbia University\",\"ETH Zurich \\u2013 Swiss Federal Institute of Technology Zurich\",\"Johns Hopkins University\",\"University of Pennsylvania\",\"Duke University\",\"University of Michigan\",\"Cornell University\",\"University of Toronto\",\"University College London\",\"Northwestern University\",\"University of Tokyo\",\"Carnegie Mellon University\",\"University of Washington\",\"National University of Singapore\",\"University of Texas at Austin\",\"Georgia Institute of Technology\",\"University of Illinois at Urbana-Champaign\",\"University of Wisconsin-Madison\",\"University of British Columbia\",\"London School of Economics and Political Science\",\"University of California, Santa Barbara\",\"University of Melbourne\",\"McGill University\",\"Karolinska Institute\",\"\\u00c9cole Polytechnique F\\u00e9d\\u00e9rale de Lausanne\",\"King\\u2019s College London\",\"University of Edinburgh\",\"New York University\",\"University of California, San Diego\",\"Washington University in St Louis\",\"University of Hong Kong\",\"Seoul National University\",\"Peking University\",\"University of Minnesota\",\"University of North Carolina at Chapel Hill\",\"Australian National University\",\"Pennsylvania State University\",\"Boston University\",\"Tsinghua University\",\"Brown University\",\"Kyoto University\",\"University of California, Davis\",\"LMU Munich\",\"Korea Advanced Institute of Science and Technology (KAIST)\",\"Hong Kong University of Science and Technology\",\"University of Manchester\",\"Ohio State University\",\"Pohang University of Science and Technology\",\"KU Leuven\",\"Purdue University\",\"The University of Queensland\",\"University of G\\u00f6ttingen\",\"Rice University\",\"\\u00c9cole Normale Sup\\u00e9rieure\",\"Leiden University\",\"Heidelberg University\",\"Delft University of Technology\",\"University of Southern California\",\"\\u00c9cole Polytechnique\",\"University of Sydney\",\"Erasmus University Rotterdam\",\"University of Basel\",\"Utrecht University\",\"Nanyang Technological University\",\"Wageningen University and Research Center\",\"University of Pittsburgh\",\"University of Bristol\",\"Durham University\",\"Emory University\",\"Tufts University\",\"Michigan State University\",\"University of Amsterdam\",\"Ghent University\",\"Free University of Berlin\",\"Technical University of Munich\",\"Case Western Reserve University\",\"Vanderbilt University\",\"University of Notre Dame\",\"Monash University\",\"McMaster University\",\"University of California, Irvine\",\"Humboldt University of Berlin\",\"University of Rochester\",\"Pierre and Marie Curie University\",\"University of Colorado Boulder\",\"Maastricht University\",\"University of Groningen\",\"University of Helsinki\"],\"x\":[\"1\",\"2\",\"2\",\"4\",\"5\",\"6\",\"7\",\"8\",\"9\",\"10\",\"11\",\"12\",\"13\",\"14\",\"15\",\"16\",\"17\",\"18\",\"19\",\"20\",\"21\",\"22\",\"23\",\"24\",\"25\",\"26\",\"27\",\"28\",\"29\",\"30\",\"31\",\"32\",\"33\",\"34\",\"35\",\"36\",\"37\",\"38\",\"39\",\"40\",\"40\",\"42\",\"43\",\"44\",\"45\",\"46\",\"47\",\"48\",\"49\",\"50\",\"50\",\"52\",\"52\",\"52\",\"55\",\"56\",\"57\",\"58\",\"59\",\"60\",\"61\",\"62\",\"63\",\"63\",\"65\",\"65\",\"67\",\"68\",\"69\",\"70\",\"70\",\"72\",\"73\",\"74\",\"74\",\"76\",\"77\",\"78\",\"79\",\"80\",\"80\",\"80\",\"83\",\"83\",\"85\",\"86\",\"87\",\"88\",\"88\",\"90\",\"91\",\"92\",\"93\",\"94\",\"95\",\"96\",\"97\",\"98\",\"98\",\"100\"],\"y\":[99.8,99.1,95.4,99.1,100.0,99.7,95.7,99.3,98.0,90.0,93.5,95.6,95.6,85.0,95.0,95.0,96.7,90.8,90.8,84.5,84.1,97.1,69.8,93.9,95.6,66.4,91.3,87.9,79.4,87.2,83.7,69.2,99.4,80.2,74.5,76.0,95.9,87.6,87.6,87.9,96.7,96.4,61.5,47.3,62.8,81.2,90.2,71.2,79.4,95.3,59.9,91.3,58.2,81.2,83.3,67.0,72.3,77.3,79.4,85.7,72.9,67.0,73.3,89.6,99.9,87.0,84.2,76.0,47.2,81.2,82.3,66.6,81.2,81.4,82.0,67.5,74.1,84.4,84.9,88.2,90.8,93.9,71.5,75.0,74.9,64.8,80.7,82.8,86.5,91.8,65.4,79.4,89.7,68.4,89.7,82.3,97.3,65.8,71.1,77.8],\"type\":\"scatter\"},{\"marker\":{\"color\":\"rgba(255, 128, 2, 0.8)\"},\"mode\":\"markers\",\"name\":\"2015\",\"text\":[\"California Institute of Technology\",\"Harvard University\",\"University of Oxford\",\"Stanford University\",\"University of Cambridge\",\"Massachusetts Institute of Technology\",\"Princeton University\",\"University of California, Berkeley\",\"Imperial College London\",\"Yale University\",\"University of Chicago\",\"University of California, Los Angeles\",\"ETH Zurich \\u2013 Swiss Federal Institute of Technology Zurich\",\"Columbia University\",\"Johns Hopkins University\",\"University of Pennsylvania\",\"University of Michigan\",\"Duke University\",\"Cornell University\",\"University of Toronto\",\"Northwestern University\",\"University College London\",\"University of Tokyo\",\"Carnegie Mellon University\",\"National University of Singapore\",\"University of Washington\",\"Georgia Institute of Technology\",\"University of Texas at Austin\",\"LMU Munich\",\"University of Illinois at Urbana-Champaign\",\"University of Wisconsin-Madison\",\"University of British Columbia\",\"University of Melbourne\",\"London School of Economics and Political Science\",\"\\u00c9cole Polytechnique F\\u00e9d\\u00e9rale de Lausanne\",\"University of Edinburgh\",\"University of California, Santa Barbara\",\"New York University\",\"McGill University\",\"King\\u2019s College London\",\"University of California, San Diego\",\"Washington University in St Louis\",\"University of Hong Kong\",\"Karolinska Institute\",\"Australian National University\",\"University of Minnesota\",\"University of North Carolina at Chapel Hill\",\"Peking University\",\"Tsinghua University\",\"Seoul National University\",\"Hong Kong University of Science and Technology\",\"Korea Advanced Institute of Science and Technology (KAIST)\",\"University of Manchester\",\"Brown University\",\"KU Leuven\",\"University of California, Davis\",\"Boston University\",\"Pennsylvania State University\",\"Kyoto University\",\"University of Sydney\",\"Nanyang Technological University\",\"\\u00c9cole Polytechnique\",\"Scuola Normale Superiore di Pisa\",\"Leiden University\",\"The University of Queensland\",\"Pohang University of Science and Technology\",\"University of G\\u00f6ttingen\",\"Ohio State University\",\"Rice University\",\"Heidelberg University\",\"Delft University of Technology\",\"Erasmus University Rotterdam\",\"Wageningen University and Research Center\",\"University of Bristol\",\"University of Basel\",\"University of Southern California\",\"University of Amsterdam\",\"\\u00c9cole Normale Sup\\u00e9rieure\",\"Utrecht University\",\"Humboldt University of Berlin\",\"Free University of Berlin\",\"Michigan State University\",\"Durham University\",\"Monash University\",\"Middle East Technical University\",\"University of Arizona\",\"University of Notre Dame\",\"Tufts University\",\"University of California, Irvine\",\"Ghent University\",\"University of Massachusetts\",\"University of Pittsburgh\",\"Emory University\",\"McMaster University\",\"University of Glasgow\",\"Vanderbilt University\",\"University of Colorado Boulder\",\"Stockholm University\",\"Technical University of Munich\",\"Uppsala University\"],\"x\":[\"1\",\"2\",\"3\",\"4\",\"5\",\"6\",\"7\",\"8\",\"9\",\"9\",\"11\",\"12\",\"13\",\"14\",\"15\",\"16\",\"17\",\"18\",\"19\",\"20\",\"21\",\"22\",\"23\",\"24\",\"25\",\"26\",\"27\",\"28\",\"29\",\"29\",\"29\",\"32\",\"33\",\"34\",\"34\",\"36\",\"37\",\"38\",\"39\",\"40\",\"41\",\"42\",\"43\",\"44\",\"45\",\"46\",\"46\",\"48\",\"49\",\"50\",\"51\",\"52\",\"52\",\"54\",\"55\",\"55\",\"57\",\"58\",\"59\",\"60\",\"61\",\"61\",\"63\",\"64\",\"65\",\"66\",\"67\",\"68\",\"69\",\"70\",\"71\",\"72\",\"73\",\"74\",\"75\",\"75\",\"77\",\"78\",\"79\",\"80\",\"81\",\"82\",\"83\",\"83\",\"85\",\"86\",\"86\",\"88\",\"88\",\"90\",\"91\",\"91\",\"93\",\"94\",\"94\",\"96\",\"97\",\"98\",\"98\",\"98\"],\"y\":[99.7,98.9,95.5,99.1,95.2,100.0,99.6,99.1,89.4,94.0,97.3,95.3,83.5,95.3,93.6,94.4,88.9,96.6,91.5,83.0,96.9,85.1,74.7,92.0,66.0,95.0,85.8,91.5,83.0,77.8,87.7,85.3,80.6,71.3,95.0,88.3,99.2,89.5,76.0,88.3,96.4,97.1,65.1,76.8,71.1,82.9,91.0,63.7,65.0,48.7,72.9,71.4,74.3,92.0,71.8,80.4,94.4,76.0,57.0,69.0,75.9,79.9,96.4,82.3,74.2,84.4,92.3,80.4,99.9,81.4,42.6,82.3,77.5,85.1,81.4,81.3,76.6,84.8,80.0,71.9,67.6,74.0,88.9,65.7,92.0,74.0,90.0,92.9,89.5,73.8,78.7,84.4,89.5,78.8,83.7,87.7,97.4,90.9,78.8,70.9],\"type\":\"scatter\"},{\"marker\":{\"color\":\"rgba(0, 255, 200, 0.8)\"},\"mode\":\"markers\",\"name\":\"2016\",\"text\":[\"California Institute of Technology\",\"University of Oxford\",\"Stanford University\",\"University of Cambridge\",\"Massachusetts Institute of Technology\",\"Harvard University\",\"Princeton University\",\"Imperial College London\",\"ETH Zurich \\u2013 Swiss Federal Institute of Technology Zurich\",\"University of Chicago\",\"Johns Hopkins University\",\"Yale University\",\"University of California, Berkeley\",\"University College London\",\"Columbia University\",\"University of California, Los Angeles\",\"University of Pennsylvania\",\"Cornell University\",\"University of Toronto\",\"Duke University\",\"University of Michigan\",\"Carnegie Mellon University\",\"London School of Economics and Political Science\",\"University of Edinburgh\",\"Northwestern University\",\"National University of Singapore\",\"King\\u2019s College London\",\"Karolinska Institute\",\"LMU Munich\",\"New York University\",\"\\u00c9cole Polytechnique F\\u00e9d\\u00e9rale de Lausanne\",\"University of Washington\",\"University of Melbourne\",\"University of British Columbia\",\"KU Leuven\",\"University of Illinois at Urbana-Champaign\",\"Heidelberg University\",\"McGill University\",\"University of California, San Diego\",\"University of California, Santa Barbara\",\"Georgia Institute of Technology\",\"Peking University\",\"University of Tokyo\",\"University of California, Davis\",\"University of Hong Kong\",\"University of Texas at Austin\",\"Tsinghua University\",\"Wageningen University and Research Center\",\"Humboldt University of Berlin\",\"University of Wisconsin-Madison\",\"Brown University\",\"Australian National University\",\"Technical University of Munich\",\"\\u00c9cole Normale Sup\\u00e9rieure\",\"Nanyang Technological University\",\"University of Manchester\",\"University of Sydney\",\"University of Amsterdam\",\"Hong Kong University of Science and Technology\",\"The University of Queensland\",\"Washington University in St Louis\",\"Utrecht University\",\"University of North Carolina at Chapel Hill\",\"Boston University\",\"Delft University of Technology\",\"University of Minnesota\",\"Leiden University\",\"University of Southern California\",\"University of Bristol\",\"Durham University\",\"Erasmus University Rotterdam\",\"Free University of Berlin\",\"Monash University\",\"University of Groningen\",\"Pennsylvania State University\",\"University of Glasgow\",\"University of Helsinki\",\"University of T\\u00fcbingen\",\"University of Pittsburgh\",\"University of Warwick\",\"Uppsala University\",\"University of Copenhagen\",\"University of New South Wales\",\"University of Freiburg\",\"Seoul National University\",\"University of St Andrews\",\"Vanderbilt University\",\"Kyoto University\",\"Maastricht University\",\"Emory University\",\"Lund University\",\"Ohio State University\",\"University of Exeter\",\"University of Bonn\",\"Georgetown University\",\"McMaster University\",\"University of Sheffield\",\"Queen Mary University of London\",\"University of G\\u00f6ttingen\",\"Michigan State University\"],\"x\":[\"1\",\"2\",\"3\",\"4\",\"5\",\"6\",\"7\",\"8\",\"9\",\"10\",\"11\",\"12\",\"13\",\"14\",\"15\",\"16\",\"17\",\"18\",\"19\",\"20\",\"21\",\"22\",\"23\",\"24\",\"25\",\"26\",\"27\",\"28\",\"29\",\"30\",\"31\",\"32\",\"33\",\"34\",\"35\",\"36\",\"37\",\"38\",\"=39\",\"=39\",\"41\",\"42\",\"43\",\"=44\",\"=44\",\"46\",\"=47\",\"=47\",\"49\",\"50\",\"51\",\"52\",\"53\",\"54\",\"55\",\"=56\",\"=56\",\"58\",\"59\",\"=60\",\"=60\",\"62\",\"63\",\"64\",\"=65\",\"=65\",\"67\",\"68\",\"69\",\"70\",\"71\",\"72\",\"73\",\"74\",\"75\",\"=76\",\"=76\",\"78\",\"79\",\"80\",\"81\",\"=82\",\"=82\",\"84\",\"85\",\"86\",\"87\",\"=88\",\"=88\",\"=90\",\"=90\",\"=90\",\"93\",\"=94\",\"=94\",\"=94\",\"97\",\"98\",\"=99\",\"=99\"],\"y\":[99.8,98.8,99.9,97.0,99.7,99.8,99.3,96.7,91.1,99.2,98.2,97.2,99.7,94.2,98.1,98.5,98.6,97.2,90.9,99.0,94.4,99.1,94.3,96.3,96.5,79.4,93.8,92.2,85.7,95.3,94.6,98.6,86.6,91.5,87.3,86.8,88.2,78.9,98.7,99.2,86.0,69.1,60.9,84.3,70.1,92.2,58.8,87.8,73.6,86.6,96.4,72.3,80.1,87.1,85.6,77.3,77.5,87.4,82.6,82.4,99.2,88.1,95.9,97.7,61.5,88.0,85.2,93.0,91.2,87.7,95.6,60.2,73.3,84.0,80.5,92.3,82.1,79.3,92.3,78.2,80.9,86.2,82.1,80.5,50.0,78.8,95.7,46.6,82.7,96.7,81.3,83.2,94.3,85.3,82.5,84.9,80.1,93.3,72.7,76.8],\"type\":\"scatter\"}],                        {\"template\":{\"data\":{\"barpolar\":[{\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"barpolar\"}],\"bar\":[{\"error_x\":{\"color\":\"#2a3f5f\"},\"error_y\":{\"color\":\"#2a3f5f\"},\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"bar\"}],\"carpet\":[{\"aaxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"baxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"type\":\"carpet\"}],\"choropleth\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"choropleth\"}],\"contourcarpet\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"contourcarpet\"}],\"contour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"contour\"}],\"heatmapgl\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmapgl\"}],\"heatmap\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmap\"}],\"histogram2dcontour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2dcontour\"}],\"histogram2d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2d\"}],\"histogram\":[{\"marker\":{\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"histogram\"}],\"mesh3d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"mesh3d\"}],\"parcoords\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"parcoords\"}],\"pie\":[{\"automargin\":true,\"type\":\"pie\"}],\"scatter3d\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatter3d\"}],\"scattercarpet\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattercarpet\"}],\"scattergeo\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergeo\"}],\"scattergl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergl\"}],\"scattermapbox\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattermapbox\"}],\"scatterpolargl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolargl\"}],\"scatterpolar\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolar\"}],\"scatter\":[{\"fillpattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2},\"type\":\"scatter\"}],\"scatterternary\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterternary\"}],\"surface\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"surface\"}],\"table\":[{\"cells\":{\"fill\":{\"color\":\"#EBF0F8\"},\"line\":{\"color\":\"white\"}},\"header\":{\"fill\":{\"color\":\"#C8D4E3\"},\"line\":{\"color\":\"white\"}},\"type\":\"table\"}]},\"layout\":{\"annotationdefaults\":{\"arrowcolor\":\"#2a3f5f\",\"arrowhead\":0,\"arrowwidth\":1},\"autotypenumbers\":\"strict\",\"coloraxis\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"colorscale\":{\"diverging\":[[0,\"#8e0152\"],[0.1,\"#c51b7d\"],[0.2,\"#de77ae\"],[0.3,\"#f1b6da\"],[0.4,\"#fde0ef\"],[0.5,\"#f7f7f7\"],[0.6,\"#e6f5d0\"],[0.7,\"#b8e186\"],[0.8,\"#7fbc41\"],[0.9,\"#4d9221\"],[1,\"#276419\"]],\"sequential\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"sequentialminus\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]]},\"colorway\":[\"#636efa\",\"#EF553B\",\"#00cc96\",\"#ab63fa\",\"#FFA15A\",\"#19d3f3\",\"#FF6692\",\"#B6E880\",\"#FF97FF\",\"#FECB52\"],\"font\":{\"color\":\"#2a3f5f\"},\"geo\":{\"bgcolor\":\"white\",\"lakecolor\":\"white\",\"landcolor\":\"#E5ECF6\",\"showlakes\":true,\"showland\":true,\"subunitcolor\":\"white\"},\"hoverlabel\":{\"align\":\"left\"},\"hovermode\":\"closest\",\"mapbox\":{\"style\":\"light\"},\"paper_bgcolor\":\"white\",\"plot_bgcolor\":\"#E5ECF6\",\"polar\":{\"angularaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"radialaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"scene\":{\"xaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"yaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"zaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"}},\"shapedefaults\":{\"line\":{\"color\":\"#2a3f5f\"}},\"ternary\":{\"aaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"baxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"caxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"title\":{\"x\":0.05},\"xaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2},\"yaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2}}},\"title\":{\"text\":\"Citation vs world rank of top 100 universities with 2014, 2015 and 2016 years\"},\"xaxis\":{\"ticklen\":5,\"title\":{\"text\":\"World Rank\"},\"zeroline\":false},\"yaxis\":{\"ticklen\":5,\"title\":{\"text\":\"Citation\"},\"zeroline\":false}},                        {\"responsive\": true}                    ).then(function(){\n",
       "                            \n",
       "var gd = document.getElementById('e7f720f6-9559-453d-9182-adf198419126');\n",
       "var x = new MutationObserver(function (mutations, observer) {{\n",
       "        var display = window.getComputedStyle(gd).display;\n",
       "        if (!display || display === 'none') {{\n",
       "            console.log([gd, 'removed!']);\n",
       "            Plotly.purge(gd);\n",
       "            observer.disconnect();\n",
       "        }}\n",
       "}});\n",
       "\n",
       "// Listen for the removal of the full notebook cells\n",
       "var notebookContainer = gd.closest('#notebook-container');\n",
       "if (notebookContainer) {{\n",
       "    x.observe(notebookContainer, {childList: true});\n",
       "}}\n",
       "\n",
       "// Listen for the clearing of the current output cell\n",
       "var outputEl = gd.closest('.output');\n",
       "if (outputEl) {{\n",
       "    x.observe(outputEl, {childList: true});\n",
       "}}\n",
       "\n",
       "                        })                };                });            </script>        </div>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "# prepare data frames\n",
    "df2014 = timesData[timesData.year == 2014].iloc[:100,:]\n",
    "df2015 = timesData[timesData.year == 2015].iloc[:100,:]\n",
    "df2016 = timesData[timesData.year == 2016].iloc[:100,:]\n",
    "# import graph objects as \"go\"\n",
    "import plotly.graph_objs as go\n",
    "# creating trace1\n",
    "trace1 =go.Scatter(\n",
    "                    x = df2014.world_rank,\n",
    "                    y = df2014.citations,\n",
    "                    mode = \"markers\",\n",
    "                    name = \"2014\",\n",
    "                    marker = dict(color = 'rgba(255, 128, 255, 0.8)'),\n",
    "                    text= df2014.university_name)\n",
    "# creating trace2\n",
    "trace2 =go.Scatter(\n",
    "                    x = df2015.world_rank,\n",
    "                    y = df2015.citations,\n",
    "                    mode = \"markers\",\n",
    "                    name = \"2015\",\n",
    "                    marker = dict(color = 'rgba(255, 128, 2, 0.8)'),\n",
    "                    text= df2015.university_name)\n",
    "# creating trace3\n",
    "trace3 =go.Scatter(\n",
    "                    x = df2016.world_rank,\n",
    "                    y = df2016.citations,\n",
    "                    mode = \"markers\",\n",
    "                    name = \"2016\",\n",
    "                    marker = dict(color = 'rgba(0, 255, 200, 0.8)'),\n",
    "                    text= df2016.university_name)\n",
    "data = [trace1, trace2, trace3]\n",
    "layout = dict(title = 'Citation vs world rank of top 100 universities with 2014, 2015 and 2016 years',\n",
    "              xaxis= dict(title= 'World Rank',ticklen= 5,zeroline= False),\n",
    "              yaxis= dict(title= 'Citation',ticklen= 5,zeroline= False)\n",
    "             )\n",
    "fig = dict(data = data, layout = layout)\n",
    "iplot(fig)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.plotly.v1+json": {
       "config": {
        "linkText": "Export to plot.ly",
        "plotlyServerURL": "https://plot.ly",
        "showLink": false
       },
       "data": [
        {
         "marker": {
          "color": "rgba(255, 174, 255, 0.5)",
          "line": {
           "color": "rgb(0,0,0)",
           "width": 1.5
          }
         },
         "name": "citations",
         "text": [
          "United States of America",
          "United States of America",
          "United Kingdom"
         ],
         "type": "bar",
         "x": [
          "California Institute of Technology",
          "Harvard University",
          "University of Oxford"
         ],
         "y": [
          99.8,
          99.1,
          95.4
         ]
        },
        {
         "marker": {
          "color": "rgba(255, 255, 128, 0.5)",
          "line": {
           "color": "rgb(0,0,0)",
           "width": 1.5
          }
         },
         "name": "teaching",
         "text": [
          "United States of America",
          "United States of America",
          "United Kingdom"
         ],
         "type": "bar",
         "x": [
          "California Institute of Technology",
          "Harvard University",
          "University of Oxford"
         ],
         "y": [
          94.4,
          95.3,
          89
         ]
        }
       ],
       "layout": {
        "barmode": "group",
        "template": {
         "data": {
          "bar": [
           {
            "error_x": {
             "color": "#2a3f5f"
            },
            "error_y": {
             "color": "#2a3f5f"
            },
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "bar"
           }
          ],
          "barpolar": [
           {
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "barpolar"
           }
          ],
          "carpet": [
           {
            "aaxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "baxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "type": "carpet"
           }
          ],
          "choropleth": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "choropleth"
           }
          ],
          "contour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "contour"
           }
          ],
          "contourcarpet": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "contourcarpet"
           }
          ],
          "heatmap": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmap"
           }
          ],
          "heatmapgl": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmapgl"
           }
          ],
          "histogram": [
           {
            "marker": {
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "histogram"
           }
          ],
          "histogram2d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2d"
           }
          ],
          "histogram2dcontour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2dcontour"
           }
          ],
          "mesh3d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "mesh3d"
           }
          ],
          "parcoords": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "parcoords"
           }
          ],
          "pie": [
           {
            "automargin": true,
            "type": "pie"
           }
          ],
          "scatter": [
           {
            "fillpattern": {
             "fillmode": "overlay",
             "size": 10,
             "solidity": 0.2
            },
            "type": "scatter"
           }
          ],
          "scatter3d": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatter3d"
           }
          ],
          "scattercarpet": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattercarpet"
           }
          ],
          "scattergeo": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergeo"
           }
          ],
          "scattergl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergl"
           }
          ],
          "scattermapbox": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattermapbox"
           }
          ],
          "scatterpolar": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolar"
           }
          ],
          "scatterpolargl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolargl"
           }
          ],
          "scatterternary": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterternary"
           }
          ],
          "surface": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "surface"
           }
          ],
          "table": [
           {
            "cells": {
             "fill": {
              "color": "#EBF0F8"
             },
             "line": {
              "color": "white"
             }
            },
            "header": {
             "fill": {
              "color": "#C8D4E3"
             },
             "line": {
              "color": "white"
             }
            },
            "type": "table"
           }
          ]
         },
         "layout": {
          "annotationdefaults": {
           "arrowcolor": "#2a3f5f",
           "arrowhead": 0,
           "arrowwidth": 1
          },
          "autotypenumbers": "strict",
          "coloraxis": {
           "colorbar": {
            "outlinewidth": 0,
            "ticks": ""
           }
          },
          "colorscale": {
           "diverging": [
            [
             0,
             "#8e0152"
            ],
            [
             0.1,
             "#c51b7d"
            ],
            [
             0.2,
             "#de77ae"
            ],
            [
             0.3,
             "#f1b6da"
            ],
            [
             0.4,
             "#fde0ef"
            ],
            [
             0.5,
             "#f7f7f7"
            ],
            [
             0.6,
             "#e6f5d0"
            ],
            [
             0.7,
             "#b8e186"
            ],
            [
             0.8,
             "#7fbc41"
            ],
            [
             0.9,
             "#4d9221"
            ],
            [
             1,
             "#276419"
            ]
           ],
           "sequential": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ],
           "sequentialminus": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ]
          },
          "colorway": [
           "#636efa",
           "#EF553B",
           "#00cc96",
           "#ab63fa",
           "#FFA15A",
           "#19d3f3",
           "#FF6692",
           "#B6E880",
           "#FF97FF",
           "#FECB52"
          ],
          "font": {
           "color": "#2a3f5f"
          },
          "geo": {
           "bgcolor": "white",
           "lakecolor": "white",
           "landcolor": "#E5ECF6",
           "showlakes": true,
           "showland": true,
           "subunitcolor": "white"
          },
          "hoverlabel": {
           "align": "left"
          },
          "hovermode": "closest",
          "mapbox": {
           "style": "light"
          },
          "paper_bgcolor": "white",
          "plot_bgcolor": "#E5ECF6",
          "polar": {
           "angularaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "radialaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "scene": {
           "xaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "yaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "zaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           }
          },
          "shapedefaults": {
           "line": {
            "color": "#2a3f5f"
           }
          },
          "ternary": {
           "aaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "baxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "caxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "title": {
           "x": 0.05
          },
          "xaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          },
          "yaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          }
         }
        }
       }
      },
      "text/html": [
       "<div>                            <div id=\"8976996e-6bba-46cb-9ea6-15dad1eb3382\" class=\"plotly-graph-div\" style=\"height:525px; width:100%;\"></div>            <script type=\"text/javascript\">                require([\"plotly\"], function(Plotly) {                    window.PLOTLYENV=window.PLOTLYENV || {};                                    if (document.getElementById(\"8976996e-6bba-46cb-9ea6-15dad1eb3382\")) {                    Plotly.newPlot(                        \"8976996e-6bba-46cb-9ea6-15dad1eb3382\",                        [{\"marker\":{\"color\":\"rgba(255, 174, 255, 0.5)\",\"line\":{\"color\":\"rgb(0,0,0)\",\"width\":1.5}},\"name\":\"citations\",\"text\":[\"United States of America\",\"United States of America\",\"United Kingdom\"],\"x\":[\"California Institute of Technology\",\"Harvard University\",\"University of Oxford\"],\"y\":[99.8,99.1,95.4],\"type\":\"bar\"},{\"marker\":{\"color\":\"rgba(255, 255, 128, 0.5)\",\"line\":{\"color\":\"rgb(0,0,0)\",\"width\":1.5}},\"name\":\"teaching\",\"text\":[\"United States of America\",\"United States of America\",\"United Kingdom\"],\"x\":[\"California Institute of Technology\",\"Harvard University\",\"University of Oxford\"],\"y\":[94.4,95.3,89.0],\"type\":\"bar\"}],                        {\"barmode\":\"group\",\"template\":{\"data\":{\"barpolar\":[{\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"barpolar\"}],\"bar\":[{\"error_x\":{\"color\":\"#2a3f5f\"},\"error_y\":{\"color\":\"#2a3f5f\"},\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"bar\"}],\"carpet\":[{\"aaxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"baxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"type\":\"carpet\"}],\"choropleth\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"choropleth\"}],\"contourcarpet\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"contourcarpet\"}],\"contour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"contour\"}],\"heatmapgl\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmapgl\"}],\"heatmap\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmap\"}],\"histogram2dcontour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2dcontour\"}],\"histogram2d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2d\"}],\"histogram\":[{\"marker\":{\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"histogram\"}],\"mesh3d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"mesh3d\"}],\"parcoords\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"parcoords\"}],\"pie\":[{\"automargin\":true,\"type\":\"pie\"}],\"scatter3d\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatter3d\"}],\"scattercarpet\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattercarpet\"}],\"scattergeo\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergeo\"}],\"scattergl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergl\"}],\"scattermapbox\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattermapbox\"}],\"scatterpolargl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolargl\"}],\"scatterpolar\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolar\"}],\"scatter\":[{\"fillpattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2},\"type\":\"scatter\"}],\"scatterternary\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterternary\"}],\"surface\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"surface\"}],\"table\":[{\"cells\":{\"fill\":{\"color\":\"#EBF0F8\"},\"line\":{\"color\":\"white\"}},\"header\":{\"fill\":{\"color\":\"#C8D4E3\"},\"line\":{\"color\":\"white\"}},\"type\":\"table\"}]},\"layout\":{\"annotationdefaults\":{\"arrowcolor\":\"#2a3f5f\",\"arrowhead\":0,\"arrowwidth\":1},\"autotypenumbers\":\"strict\",\"coloraxis\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"colorscale\":{\"diverging\":[[0,\"#8e0152\"],[0.1,\"#c51b7d\"],[0.2,\"#de77ae\"],[0.3,\"#f1b6da\"],[0.4,\"#fde0ef\"],[0.5,\"#f7f7f7\"],[0.6,\"#e6f5d0\"],[0.7,\"#b8e186\"],[0.8,\"#7fbc41\"],[0.9,\"#4d9221\"],[1,\"#276419\"]],\"sequential\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"sequentialminus\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]]},\"colorway\":[\"#636efa\",\"#EF553B\",\"#00cc96\",\"#ab63fa\",\"#FFA15A\",\"#19d3f3\",\"#FF6692\",\"#B6E880\",\"#FF97FF\",\"#FECB52\"],\"font\":{\"color\":\"#2a3f5f\"},\"geo\":{\"bgcolor\":\"white\",\"lakecolor\":\"white\",\"landcolor\":\"#E5ECF6\",\"showlakes\":true,\"showland\":true,\"subunitcolor\":\"white\"},\"hoverlabel\":{\"align\":\"left\"},\"hovermode\":\"closest\",\"mapbox\":{\"style\":\"light\"},\"paper_bgcolor\":\"white\",\"plot_bgcolor\":\"#E5ECF6\",\"polar\":{\"angularaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"radialaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"scene\":{\"xaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"yaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"zaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"}},\"shapedefaults\":{\"line\":{\"color\":\"#2a3f5f\"}},\"ternary\":{\"aaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"baxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"caxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"title\":{\"x\":0.05},\"xaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2},\"yaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2}}}},                        {\"responsive\": true}                    ).then(function(){\n",
       "                            \n",
       "var gd = document.getElementById('8976996e-6bba-46cb-9ea6-15dad1eb3382');\n",
       "var x = new MutationObserver(function (mutations, observer) {{\n",
       "        var display = window.getComputedStyle(gd).display;\n",
       "        if (!display || display === 'none') {{\n",
       "            console.log([gd, 'removed!']);\n",
       "            Plotly.purge(gd);\n",
       "            observer.disconnect();\n",
       "        }}\n",
       "}});\n",
       "\n",
       "// Listen for the removal of the full notebook cells\n",
       "var notebookContainer = gd.closest('#notebook-container');\n",
       "if (notebookContainer) {{\n",
       "    x.observe(notebookContainer, {childList: true});\n",
       "}}\n",
       "\n",
       "// Listen for the clearing of the current output cell\n",
       "var outputEl = gd.closest('.output');\n",
       "if (outputEl) {{\n",
       "    x.observe(outputEl, {childList: true});\n",
       "}}\n",
       "\n",
       "                        })                };                });            </script>        </div>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "# prepare data frames\n",
    "df2014 = timesData[timesData.year == 2014].iloc[:3,:]\n",
    "# import graph objects as \"go\"\n",
    "import plotly.graph_objs as go\n",
    "# create trace1 \n",
    "trace1 = go.Bar(\n",
    "                x = df2014.university_name,\n",
    "                y = df2014.citations,\n",
    "                name = \"citations\",\n",
    "                marker = dict(color = 'rgba(255, 174, 255, 0.5)',\n",
    "                             line=dict(color='rgb(0,0,0)',width=1.5)),\n",
    "                text = df2014.country)\n",
    "# create trace2 \n",
    "trace2 = go.Bar(\n",
    "                x = df2014.university_name,\n",
    "                y = df2014.teaching,\n",
    "                name = \"teaching\",\n",
    "                marker = dict(color = 'rgba(255, 255, 128, 0.5)',\n",
    "                              line=dict(color='rgb(0,0,0)',width=1.5)),\n",
    "                text = df2014.country)\n",
    "data = [trace1, trace2]\n",
    "layout = go.Layout(barmode = \"group\")\n",
    "fig = go.Figure(data = data, layout = layout)\n",
    "iplot(fig)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "application/vnd.plotly.v1+json": {
       "config": {
        "linkText": "Export to plot.ly",
        "plotlyServerURL": "https://plot.ly",
        "showLink": false
       },
       "data": [
        {
         "name": "citation",
         "type": "bar",
         "x": [
          "California Institute of Technology",
          "Harvard University",
          "University of Oxford"
         ],
         "y": [
          99.8,
          99.1,
          95.4
         ]
        },
        {
         "name": "teaching",
         "type": "bar",
         "x": [
          "California Institute of Technology",
          "Harvard University",
          "University of Oxford"
         ],
         "y": [
          94.4,
          95.3,
          89
         ]
        }
       ],
       "layout": {
        "barmode": "group",
        "template": {
         "data": {
          "bar": [
           {
            "error_x": {
             "color": "#2a3f5f"
            },
            "error_y": {
             "color": "#2a3f5f"
            },
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "bar"
           }
          ],
          "barpolar": [
           {
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "barpolar"
           }
          ],
          "carpet": [
           {
            "aaxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "baxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "type": "carpet"
           }
          ],
          "choropleth": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "choropleth"
           }
          ],
          "contour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "contour"
           }
          ],
          "contourcarpet": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "contourcarpet"
           }
          ],
          "heatmap": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmap"
           }
          ],
          "heatmapgl": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmapgl"
           }
          ],
          "histogram": [
           {
            "marker": {
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "histogram"
           }
          ],
          "histogram2d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2d"
           }
          ],
          "histogram2dcontour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2dcontour"
           }
          ],
          "mesh3d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "mesh3d"
           }
          ],
          "parcoords": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "parcoords"
           }
          ],
          "pie": [
           {
            "automargin": true,
            "type": "pie"
           }
          ],
          "scatter": [
           {
            "fillpattern": {
             "fillmode": "overlay",
             "size": 10,
             "solidity": 0.2
            },
            "type": "scatter"
           }
          ],
          "scatter3d": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatter3d"
           }
          ],
          "scattercarpet": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattercarpet"
           }
          ],
          "scattergeo": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergeo"
           }
          ],
          "scattergl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergl"
           }
          ],
          "scattermapbox": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattermapbox"
           }
          ],
          "scatterpolar": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolar"
           }
          ],
          "scatterpolargl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolargl"
           }
          ],
          "scatterternary": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterternary"
           }
          ],
          "surface": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "surface"
           }
          ],
          "table": [
           {
            "cells": {
             "fill": {
              "color": "#EBF0F8"
             },
             "line": {
              "color": "white"
             }
            },
            "header": {
             "fill": {
              "color": "#C8D4E3"
             },
             "line": {
              "color": "white"
             }
            },
            "type": "table"
           }
          ]
         },
         "layout": {
          "annotationdefaults": {
           "arrowcolor": "#2a3f5f",
           "arrowhead": 0,
           "arrowwidth": 1
          },
          "autotypenumbers": "strict",
          "coloraxis": {
           "colorbar": {
            "outlinewidth": 0,
            "ticks": ""
           }
          },
          "colorscale": {
           "diverging": [
            [
             0,
             "#8e0152"
            ],
            [
             0.1,
             "#c51b7d"
            ],
            [
             0.2,
             "#de77ae"
            ],
            [
             0.3,
             "#f1b6da"
            ],
            [
             0.4,
             "#fde0ef"
            ],
            [
             0.5,
             "#f7f7f7"
            ],
            [
             0.6,
             "#e6f5d0"
            ],
            [
             0.7,
             "#b8e186"
            ],
            [
             0.8,
             "#7fbc41"
            ],
            [
             0.9,
             "#4d9221"
            ],
            [
             1,
             "#276419"
            ]
           ],
           "sequential": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ],
           "sequentialminus": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ]
          },
          "colorway": [
           "#636efa",
           "#EF553B",
           "#00cc96",
           "#ab63fa",
           "#FFA15A",
           "#19d3f3",
           "#FF6692",
           "#B6E880",
           "#FF97FF",
           "#FECB52"
          ],
          "font": {
           "color": "#2a3f5f"
          },
          "geo": {
           "bgcolor": "white",
           "lakecolor": "white",
           "landcolor": "#E5ECF6",
           "showlakes": true,
           "showland": true,
           "subunitcolor": "white"
          },
          "hoverlabel": {
           "align": "left"
          },
          "hovermode": "closest",
          "mapbox": {
           "style": "light"
          },
          "paper_bgcolor": "white",
          "plot_bgcolor": "#E5ECF6",
          "polar": {
           "angularaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "radialaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "scene": {
           "xaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "yaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "zaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           }
          },
          "shapedefaults": {
           "line": {
            "color": "#2a3f5f"
           }
          },
          "ternary": {
           "aaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "baxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "caxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "title": {
           "x": 0.05
          },
          "xaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          },
          "yaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          }
         }
        },
        "title": {
         "text": "citations and teaching of top 3 universities in 2014"
        },
        "xaxis": {
         "title": {
          "text": "Top 3 universities"
         }
        }
       }
      },
      "text/html": [
       "<div>                            <div id=\"2b9d6d0d-fe70-4d9f-a057-df534cccd9c0\" class=\"plotly-graph-div\" style=\"height:525px; width:100%;\"></div>            <script type=\"text/javascript\">                require([\"plotly\"], function(Plotly) {                    window.PLOTLYENV=window.PLOTLYENV || {};                                    if (document.getElementById(\"2b9d6d0d-fe70-4d9f-a057-df534cccd9c0\")) {                    Plotly.newPlot(                        \"2b9d6d0d-fe70-4d9f-a057-df534cccd9c0\",                        [{\"name\":\"citation\",\"x\":[\"California Institute of Technology\",\"Harvard University\",\"University of Oxford\"],\"y\":[99.8,99.1,95.4],\"type\":\"bar\"},{\"name\":\"teaching\",\"x\":[\"California Institute of Technology\",\"Harvard University\",\"University of Oxford\"],\"y\":[94.4,95.3,89.0],\"type\":\"bar\"}],                        {\"barmode\":\"group\",\"template\":{\"data\":{\"barpolar\":[{\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"barpolar\"}],\"bar\":[{\"error_x\":{\"color\":\"#2a3f5f\"},\"error_y\":{\"color\":\"#2a3f5f\"},\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"bar\"}],\"carpet\":[{\"aaxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"baxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"type\":\"carpet\"}],\"choropleth\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"choropleth\"}],\"contourcarpet\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"contourcarpet\"}],\"contour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"contour\"}],\"heatmapgl\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmapgl\"}],\"heatmap\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmap\"}],\"histogram2dcontour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2dcontour\"}],\"histogram2d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2d\"}],\"histogram\":[{\"marker\":{\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"histogram\"}],\"mesh3d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"mesh3d\"}],\"parcoords\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"parcoords\"}],\"pie\":[{\"automargin\":true,\"type\":\"pie\"}],\"scatter3d\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatter3d\"}],\"scattercarpet\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattercarpet\"}],\"scattergeo\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergeo\"}],\"scattergl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergl\"}],\"scattermapbox\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattermapbox\"}],\"scatterpolargl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolargl\"}],\"scatterpolar\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolar\"}],\"scatter\":[{\"fillpattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2},\"type\":\"scatter\"}],\"scatterternary\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterternary\"}],\"surface\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"surface\"}],\"table\":[{\"cells\":{\"fill\":{\"color\":\"#EBF0F8\"},\"line\":{\"color\":\"white\"}},\"header\":{\"fill\":{\"color\":\"#C8D4E3\"},\"line\":{\"color\":\"white\"}},\"type\":\"table\"}]},\"layout\":{\"annotationdefaults\":{\"arrowcolor\":\"#2a3f5f\",\"arrowhead\":0,\"arrowwidth\":1},\"autotypenumbers\":\"strict\",\"coloraxis\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"colorscale\":{\"diverging\":[[0,\"#8e0152\"],[0.1,\"#c51b7d\"],[0.2,\"#de77ae\"],[0.3,\"#f1b6da\"],[0.4,\"#fde0ef\"],[0.5,\"#f7f7f7\"],[0.6,\"#e6f5d0\"],[0.7,\"#b8e186\"],[0.8,\"#7fbc41\"],[0.9,\"#4d9221\"],[1,\"#276419\"]],\"sequential\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"sequentialminus\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]]},\"colorway\":[\"#636efa\",\"#EF553B\",\"#00cc96\",\"#ab63fa\",\"#FFA15A\",\"#19d3f3\",\"#FF6692\",\"#B6E880\",\"#FF97FF\",\"#FECB52\"],\"font\":{\"color\":\"#2a3f5f\"},\"geo\":{\"bgcolor\":\"white\",\"lakecolor\":\"white\",\"landcolor\":\"#E5ECF6\",\"showlakes\":true,\"showland\":true,\"subunitcolor\":\"white\"},\"hoverlabel\":{\"align\":\"left\"},\"hovermode\":\"closest\",\"mapbox\":{\"style\":\"light\"},\"paper_bgcolor\":\"white\",\"plot_bgcolor\":\"#E5ECF6\",\"polar\":{\"angularaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"radialaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"scene\":{\"xaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"yaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"zaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"}},\"shapedefaults\":{\"line\":{\"color\":\"#2a3f5f\"}},\"ternary\":{\"aaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"baxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"caxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"title\":{\"x\":0.05},\"xaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2},\"yaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2}}},\"title\":{\"text\":\"citations and teaching of top 3 universities in 2014\"},\"xaxis\":{\"title\":{\"text\":\"Top 3 universities\"}}},                        {\"responsive\": true}                    ).then(function(){\n",
       "                            \n",
       "var gd = document.getElementById('2b9d6d0d-fe70-4d9f-a057-df534cccd9c0');\n",
       "var x = new MutationObserver(function (mutations, observer) {{\n",
       "        var display = window.getComputedStyle(gd).display;\n",
       "        if (!display || display === 'none') {{\n",
       "            console.log([gd, 'removed!']);\n",
       "            Plotly.purge(gd);\n",
       "            observer.disconnect();\n",
       "        }}\n",
       "}});\n",
       "\n",
       "// Listen for the removal of the full notebook cells\n",
       "var notebookContainer = gd.closest('#notebook-container');\n",
       "if (notebookContainer) {{\n",
       "    x.observe(notebookContainer, {childList: true});\n",
       "}}\n",
       "\n",
       "// Listen for the clearing of the current output cell\n",
       "var outputEl = gd.closest('.output');\n",
       "if (outputEl) {{\n",
       "    x.observe(outputEl, {childList: true});\n",
       "}}\n",
       "\n",
       "                        })                };                });            </script>        </div>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "# prepare data frames\n",
    "df2014 = timesData[timesData.year == 2014].iloc[:3,:]\n",
    "# import graph objects as \"go\"\n",
    "import plotly.graph_objs as go\n",
    "\n",
    "x = df2014.university_name\n",
    "\n",
    "trace1 = {\n",
    "  'x': x,\n",
    "  'y': df2014.citations,\n",
    "  'name': 'citation',\n",
    "  'type': 'bar'\n",
    "};\n",
    "trace2 = {\n",
    "  'x': x,\n",
    "  'y': df2014.teaching,\n",
    "  'name': 'teaching',\n",
    "  'type': 'bar'\n",
    "};\n",
    "data = [trace1, trace2];\n",
    "layout = {\n",
    "  'xaxis': {'title': 'Top 3 universities'},\n",
    "  'barmode': 'group',\n",
    "  'title': 'citations and teaching of top 3 universities in 2014'\n",
    "};\n",
    "fig = go.Figure(data = data, layout = layout)\n",
    "iplot(fig)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "e:\\2024-3\\PBL\\demo\\streamapp\\myven\\Lib\\site-packages\\plotly\\tools.py:455: DeprecationWarning:\n",
      "\n",
      "plotly.tools.make_subplots is deprecated, please use plotly.subplots.make_subplots instead\n",
      "\n"
     ]
    },
    {
     "data": {
      "application/vnd.plotly.v1+json": {
       "config": {
        "linkText": "Export to plot.ly",
        "plotlyServerURL": "https://plot.ly",
        "showLink": false
       },
       "data": [
        {
         "marker": {
          "color": "rgba(171, 50, 96, 0.6)",
          "line": {
           "color": "rgba(171, 50, 96, 1.0)",
           "width": 1
          }
         },
         "name": "research",
         "orientation": "h",
         "type": "bar",
         "x": [
          97.6,
          98.9,
          96.2,
          96.7,
          88.6,
          99,
          91.9
         ],
         "xaxis": "x",
         "y": [
          "California Institute of Technology",
          "University of Oxford",
          "Stanford University",
          "University of Cambridge",
          "Massachusetts Institute of Technology",
          "Harvard University",
          "Princeton University"
         ],
         "yaxis": "y"
        },
        {
         "line": {
          "color": "rgb(63, 72, 204)"
         },
         "mode": "lines+markers",
         "name": "income",
         "type": "scatter",
         "x": [
          97.8,
          73.1,
          63.3,
          55,
          95.4,
          45.2,
          52.1
         ],
         "xaxis": "x2",
         "y": [
          "California Institute of Technology",
          "University of Oxford",
          "Stanford University",
          "University of Cambridge",
          "Massachusetts Institute of Technology",
          "Harvard University",
          "Princeton University"
         ],
         "yaxis": "y2"
        }
       ],
       "layout": {
        "annotations": [
         {
          "font": {
           "color": "rgb(63, 72, 204)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "98.0",
          "x": 94,
          "xref": "x2",
          "y": "California Institute of Technology",
          "yref": "y2"
         },
         {
          "font": {
           "color": "rgb(171, 50, 96)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "97.6",
          "x": 100.6,
          "xref": "x",
          "y": "California Institute of Technology",
          "yref": "y"
         },
         {
          "font": {
           "color": "rgb(63, 72, 204)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "73.0",
          "x": 69,
          "xref": "x2",
          "y": "University of Oxford",
          "yref": "y2"
         },
         {
          "font": {
           "color": "rgb(171, 50, 96)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "98.9",
          "x": 101.9,
          "xref": "x",
          "y": "University of Oxford",
          "yref": "y"
         },
         {
          "font": {
           "color": "rgb(63, 72, 204)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "63.0",
          "x": 59,
          "xref": "x2",
          "y": "Stanford University",
          "yref": "y2"
         },
         {
          "font": {
           "color": "rgb(171, 50, 96)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "96.2",
          "x": 99.2,
          "xref": "x",
          "y": "Stanford University",
          "yref": "y"
         },
         {
          "font": {
           "color": "rgb(63, 72, 204)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "55.0",
          "x": 51,
          "xref": "x2",
          "y": "University of Cambridge",
          "yref": "y2"
         },
         {
          "font": {
           "color": "rgb(171, 50, 96)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "96.7",
          "x": 99.7,
          "xref": "x",
          "y": "University of Cambridge",
          "yref": "y"
         },
         {
          "font": {
           "color": "rgb(63, 72, 204)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "95.0",
          "x": 91,
          "xref": "x2",
          "y": "Massachusetts Institute of Technology",
          "yref": "y2"
         },
         {
          "font": {
           "color": "rgb(171, 50, 96)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "88.6",
          "x": 91.6,
          "xref": "x",
          "y": "Massachusetts Institute of Technology",
          "yref": "y"
         },
         {
          "font": {
           "color": "rgb(63, 72, 204)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "45.0",
          "x": 41,
          "xref": "x2",
          "y": "Harvard University",
          "yref": "y2"
         },
         {
          "font": {
           "color": "rgb(171, 50, 96)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "99.0",
          "x": 102,
          "xref": "x",
          "y": "Harvard University",
          "yref": "y"
         },
         {
          "font": {
           "color": "rgb(63, 72, 204)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "52.0",
          "x": 48,
          "xref": "x2",
          "y": "Princeton University",
          "yref": "y2"
         },
         {
          "font": {
           "color": "rgb(171, 50, 96)",
           "family": "Arial",
           "size": 12
          },
          "showarrow": false,
          "text": "91.9",
          "x": 94.9,
          "xref": "x",
          "y": "Princeton University",
          "yref": "y"
         }
        ],
        "legend": {
         "font": {
          "size": 10
         },
         "x": 0.029,
         "y": 1.038
        },
        "margin": {
         "b": 70,
         "l": 200,
         "r": 20,
         "t": 70
        },
        "paper_bgcolor": "rgb(248, 248, 255)",
        "plot_bgcolor": "rgb(248, 248, 255)",
        "template": {
         "data": {
          "bar": [
           {
            "error_x": {
             "color": "#2a3f5f"
            },
            "error_y": {
             "color": "#2a3f5f"
            },
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "bar"
           }
          ],
          "barpolar": [
           {
            "marker": {
             "line": {
              "color": "#E5ECF6",
              "width": 0.5
             },
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "barpolar"
           }
          ],
          "carpet": [
           {
            "aaxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "baxis": {
             "endlinecolor": "#2a3f5f",
             "gridcolor": "white",
             "linecolor": "white",
             "minorgridcolor": "white",
             "startlinecolor": "#2a3f5f"
            },
            "type": "carpet"
           }
          ],
          "choropleth": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "choropleth"
           }
          ],
          "contour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "contour"
           }
          ],
          "contourcarpet": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "contourcarpet"
           }
          ],
          "heatmap": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmap"
           }
          ],
          "heatmapgl": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "heatmapgl"
           }
          ],
          "histogram": [
           {
            "marker": {
             "pattern": {
              "fillmode": "overlay",
              "size": 10,
              "solidity": 0.2
             }
            },
            "type": "histogram"
           }
          ],
          "histogram2d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2d"
           }
          ],
          "histogram2dcontour": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "histogram2dcontour"
           }
          ],
          "mesh3d": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "type": "mesh3d"
           }
          ],
          "parcoords": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "parcoords"
           }
          ],
          "pie": [
           {
            "automargin": true,
            "type": "pie"
           }
          ],
          "scatter": [
           {
            "fillpattern": {
             "fillmode": "overlay",
             "size": 10,
             "solidity": 0.2
            },
            "type": "scatter"
           }
          ],
          "scatter3d": [
           {
            "line": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatter3d"
           }
          ],
          "scattercarpet": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattercarpet"
           }
          ],
          "scattergeo": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergeo"
           }
          ],
          "scattergl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattergl"
           }
          ],
          "scattermapbox": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scattermapbox"
           }
          ],
          "scatterpolar": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolar"
           }
          ],
          "scatterpolargl": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterpolargl"
           }
          ],
          "scatterternary": [
           {
            "marker": {
             "colorbar": {
              "outlinewidth": 0,
              "ticks": ""
             }
            },
            "type": "scatterternary"
           }
          ],
          "surface": [
           {
            "colorbar": {
             "outlinewidth": 0,
             "ticks": ""
            },
            "colorscale": [
             [
              0,
              "#0d0887"
             ],
             [
              0.1111111111111111,
              "#46039f"
             ],
             [
              0.2222222222222222,
              "#7201a8"
             ],
             [
              0.3333333333333333,
              "#9c179e"
             ],
             [
              0.4444444444444444,
              "#bd3786"
             ],
             [
              0.5555555555555556,
              "#d8576b"
             ],
             [
              0.6666666666666666,
              "#ed7953"
             ],
             [
              0.7777777777777778,
              "#fb9f3a"
             ],
             [
              0.8888888888888888,
              "#fdca26"
             ],
             [
              1,
              "#f0f921"
             ]
            ],
            "type": "surface"
           }
          ],
          "table": [
           {
            "cells": {
             "fill": {
              "color": "#EBF0F8"
             },
             "line": {
              "color": "white"
             }
            },
            "header": {
             "fill": {
              "color": "#C8D4E3"
             },
             "line": {
              "color": "white"
             }
            },
            "type": "table"
           }
          ]
         },
         "layout": {
          "annotationdefaults": {
           "arrowcolor": "#2a3f5f",
           "arrowhead": 0,
           "arrowwidth": 1
          },
          "autotypenumbers": "strict",
          "coloraxis": {
           "colorbar": {
            "outlinewidth": 0,
            "ticks": ""
           }
          },
          "colorscale": {
           "diverging": [
            [
             0,
             "#8e0152"
            ],
            [
             0.1,
             "#c51b7d"
            ],
            [
             0.2,
             "#de77ae"
            ],
            [
             0.3,
             "#f1b6da"
            ],
            [
             0.4,
             "#fde0ef"
            ],
            [
             0.5,
             "#f7f7f7"
            ],
            [
             0.6,
             "#e6f5d0"
            ],
            [
             0.7,
             "#b8e186"
            ],
            [
             0.8,
             "#7fbc41"
            ],
            [
             0.9,
             "#4d9221"
            ],
            [
             1,
             "#276419"
            ]
           ],
           "sequential": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ],
           "sequentialminus": [
            [
             0,
             "#0d0887"
            ],
            [
             0.1111111111111111,
             "#46039f"
            ],
            [
             0.2222222222222222,
             "#7201a8"
            ],
            [
             0.3333333333333333,
             "#9c179e"
            ],
            [
             0.4444444444444444,
             "#bd3786"
            ],
            [
             0.5555555555555556,
             "#d8576b"
            ],
            [
             0.6666666666666666,
             "#ed7953"
            ],
            [
             0.7777777777777778,
             "#fb9f3a"
            ],
            [
             0.8888888888888888,
             "#fdca26"
            ],
            [
             1,
             "#f0f921"
            ]
           ]
          },
          "colorway": [
           "#636efa",
           "#EF553B",
           "#00cc96",
           "#ab63fa",
           "#FFA15A",
           "#19d3f3",
           "#FF6692",
           "#B6E880",
           "#FF97FF",
           "#FECB52"
          ],
          "font": {
           "color": "#2a3f5f"
          },
          "geo": {
           "bgcolor": "white",
           "lakecolor": "white",
           "landcolor": "#E5ECF6",
           "showlakes": true,
           "showland": true,
           "subunitcolor": "white"
          },
          "hoverlabel": {
           "align": "left"
          },
          "hovermode": "closest",
          "mapbox": {
           "style": "light"
          },
          "paper_bgcolor": "white",
          "plot_bgcolor": "#E5ECF6",
          "polar": {
           "angularaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "radialaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "scene": {
           "xaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "yaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           },
           "zaxis": {
            "backgroundcolor": "#E5ECF6",
            "gridcolor": "white",
            "gridwidth": 2,
            "linecolor": "white",
            "showbackground": true,
            "ticks": "",
            "zerolinecolor": "white"
           }
          },
          "shapedefaults": {
           "line": {
            "color": "#2a3f5f"
           }
          },
          "ternary": {
           "aaxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "baxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           },
           "bgcolor": "#E5ECF6",
           "caxis": {
            "gridcolor": "white",
            "linecolor": "white",
            "ticks": ""
           }
          },
          "title": {
           "x": 0.05
          },
          "xaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          },
          "yaxis": {
           "automargin": true,
           "gridcolor": "white",
           "linecolor": "white",
           "ticks": "",
           "title": {
            "standoff": 15
           },
           "zerolinecolor": "white",
           "zerolinewidth": 2
          }
         }
        },
        "title": {
         "text": "Citations and income"
        },
        "xaxis": {
         "anchor": "y",
         "domain": [
          0,
          0.42
         ],
         "showgrid": true,
         "showline": false,
         "showticklabels": true,
         "zeroline": false
        },
        "xaxis2": {
         "anchor": "y2",
         "domain": [
          0.47,
          1
         ],
         "dtick": 25,
         "showgrid": true,
         "showline": false,
         "showticklabels": true,
         "side": "top",
         "zeroline": false
        },
        "yaxis": {
         "anchor": "x",
         "domain": [
          0,
          0.85
         ],
         "showticklabels": true
        },
        "yaxis2": {
         "anchor": "x2",
         "domain": [
          0,
          0.85
         ],
         "linecolor": "rgba(102, 102, 102, 0.8)",
         "linewidth": 2,
         "matches": "y",
         "showline": true,
         "showticklabels": false
        }
       }
      },
      "text/html": [
       "<div>                            <div id=\"54c75b99-d145-4ddb-9c00-d0c47c3d8547\" class=\"plotly-graph-div\" style=\"height:525px; width:100%;\"></div>            <script type=\"text/javascript\">                require([\"plotly\"], function(Plotly) {                    window.PLOTLYENV=window.PLOTLYENV || {};                                    if (document.getElementById(\"54c75b99-d145-4ddb-9c00-d0c47c3d8547\")) {                    Plotly.newPlot(                        \"54c75b99-d145-4ddb-9c00-d0c47c3d8547\",                        [{\"marker\":{\"color\":\"rgba(171, 50, 96, 0.6)\",\"line\":{\"color\":\"rgba(171, 50, 96, 1.0)\",\"width\":1}},\"name\":\"research\",\"orientation\":\"h\",\"x\":[97.6,98.9,96.2,96.7,88.6,99.0,91.9],\"xaxis\":\"x\",\"y\":[\"California Institute of Technology\",\"University of Oxford\",\"Stanford University\",\"University of Cambridge\",\"Massachusetts Institute of Technology\",\"Harvard University\",\"Princeton University\"],\"yaxis\":\"y\",\"type\":\"bar\"},{\"line\":{\"color\":\"rgb(63, 72, 204)\"},\"mode\":\"lines+markers\",\"name\":\"income\",\"x\":[97.8,73.1,63.3,55.0,95.4,45.2,52.1],\"xaxis\":\"x2\",\"y\":[\"California Institute of Technology\",\"University of Oxford\",\"Stanford University\",\"University of Cambridge\",\"Massachusetts Institute of Technology\",\"Harvard University\",\"Princeton University\"],\"yaxis\":\"y2\",\"type\":\"scatter\"}],                        {\"annotations\":[{\"font\":{\"color\":\"rgb(63, 72, 204)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"98.0\",\"x\":94.0,\"xref\":\"x2\",\"y\":\"California Institute of Technology\",\"yref\":\"y2\"},{\"font\":{\"color\":\"rgb(171, 50, 96)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"97.6\",\"x\":100.6,\"xref\":\"x\",\"y\":\"California Institute of Technology\",\"yref\":\"y\"},{\"font\":{\"color\":\"rgb(63, 72, 204)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"73.0\",\"x\":69.0,\"xref\":\"x2\",\"y\":\"University of Oxford\",\"yref\":\"y2\"},{\"font\":{\"color\":\"rgb(171, 50, 96)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"98.9\",\"x\":101.9,\"xref\":\"x\",\"y\":\"University of Oxford\",\"yref\":\"y\"},{\"font\":{\"color\":\"rgb(63, 72, 204)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"63.0\",\"x\":59.0,\"xref\":\"x2\",\"y\":\"Stanford University\",\"yref\":\"y2\"},{\"font\":{\"color\":\"rgb(171, 50, 96)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"96.2\",\"x\":99.2,\"xref\":\"x\",\"y\":\"Stanford University\",\"yref\":\"y\"},{\"font\":{\"color\":\"rgb(63, 72, 204)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"55.0\",\"x\":51.0,\"xref\":\"x2\",\"y\":\"University of Cambridge\",\"yref\":\"y2\"},{\"font\":{\"color\":\"rgb(171, 50, 96)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"96.7\",\"x\":99.7,\"xref\":\"x\",\"y\":\"University of Cambridge\",\"yref\":\"y\"},{\"font\":{\"color\":\"rgb(63, 72, 204)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"95.0\",\"x\":91.0,\"xref\":\"x2\",\"y\":\"Massachusetts Institute of Technology\",\"yref\":\"y2\"},{\"font\":{\"color\":\"rgb(171, 50, 96)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"88.6\",\"x\":91.6,\"xref\":\"x\",\"y\":\"Massachusetts Institute of Technology\",\"yref\":\"y\"},{\"font\":{\"color\":\"rgb(63, 72, 204)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"45.0\",\"x\":41.0,\"xref\":\"x2\",\"y\":\"Harvard University\",\"yref\":\"y2\"},{\"font\":{\"color\":\"rgb(171, 50, 96)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"99.0\",\"x\":102.0,\"xref\":\"x\",\"y\":\"Harvard University\",\"yref\":\"y\"},{\"font\":{\"color\":\"rgb(63, 72, 204)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"52.0\",\"x\":48.0,\"xref\":\"x2\",\"y\":\"Princeton University\",\"yref\":\"y2\"},{\"font\":{\"color\":\"rgb(171, 50, 96)\",\"family\":\"Arial\",\"size\":12},\"showarrow\":false,\"text\":\"91.9\",\"x\":94.9,\"xref\":\"x\",\"y\":\"Princeton University\",\"yref\":\"y\"}],\"legend\":{\"font\":{\"size\":10},\"x\":0.029,\"y\":1.038},\"margin\":{\"b\":70,\"l\":200,\"r\":20,\"t\":70},\"paper_bgcolor\":\"rgb(248, 248, 255)\",\"plot_bgcolor\":\"rgb(248, 248, 255)\",\"template\":{\"data\":{\"barpolar\":[{\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"barpolar\"}],\"bar\":[{\"error_x\":{\"color\":\"#2a3f5f\"},\"error_y\":{\"color\":\"#2a3f5f\"},\"marker\":{\"line\":{\"color\":\"#E5ECF6\",\"width\":0.5},\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"bar\"}],\"carpet\":[{\"aaxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"baxis\":{\"endlinecolor\":\"#2a3f5f\",\"gridcolor\":\"white\",\"linecolor\":\"white\",\"minorgridcolor\":\"white\",\"startlinecolor\":\"#2a3f5f\"},\"type\":\"carpet\"}],\"choropleth\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"choropleth\"}],\"contourcarpet\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"contourcarpet\"}],\"contour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"contour\"}],\"heatmapgl\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmapgl\"}],\"heatmap\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"heatmap\"}],\"histogram2dcontour\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2dcontour\"}],\"histogram2d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"histogram2d\"}],\"histogram\":[{\"marker\":{\"pattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2}},\"type\":\"histogram\"}],\"mesh3d\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"type\":\"mesh3d\"}],\"parcoords\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"parcoords\"}],\"pie\":[{\"automargin\":true,\"type\":\"pie\"}],\"scatter3d\":[{\"line\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatter3d\"}],\"scattercarpet\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattercarpet\"}],\"scattergeo\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergeo\"}],\"scattergl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattergl\"}],\"scattermapbox\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scattermapbox\"}],\"scatterpolargl\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolargl\"}],\"scatterpolar\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterpolar\"}],\"scatter\":[{\"fillpattern\":{\"fillmode\":\"overlay\",\"size\":10,\"solidity\":0.2},\"type\":\"scatter\"}],\"scatterternary\":[{\"marker\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"type\":\"scatterternary\"}],\"surface\":[{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"},\"colorscale\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"type\":\"surface\"}],\"table\":[{\"cells\":{\"fill\":{\"color\":\"#EBF0F8\"},\"line\":{\"color\":\"white\"}},\"header\":{\"fill\":{\"color\":\"#C8D4E3\"},\"line\":{\"color\":\"white\"}},\"type\":\"table\"}]},\"layout\":{\"annotationdefaults\":{\"arrowcolor\":\"#2a3f5f\",\"arrowhead\":0,\"arrowwidth\":1},\"autotypenumbers\":\"strict\",\"coloraxis\":{\"colorbar\":{\"outlinewidth\":0,\"ticks\":\"\"}},\"colorscale\":{\"diverging\":[[0,\"#8e0152\"],[0.1,\"#c51b7d\"],[0.2,\"#de77ae\"],[0.3,\"#f1b6da\"],[0.4,\"#fde0ef\"],[0.5,\"#f7f7f7\"],[0.6,\"#e6f5d0\"],[0.7,\"#b8e186\"],[0.8,\"#7fbc41\"],[0.9,\"#4d9221\"],[1,\"#276419\"]],\"sequential\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]],\"sequentialminus\":[[0.0,\"#0d0887\"],[0.1111111111111111,\"#46039f\"],[0.2222222222222222,\"#7201a8\"],[0.3333333333333333,\"#9c179e\"],[0.4444444444444444,\"#bd3786\"],[0.5555555555555556,\"#d8576b\"],[0.6666666666666666,\"#ed7953\"],[0.7777777777777778,\"#fb9f3a\"],[0.8888888888888888,\"#fdca26\"],[1.0,\"#f0f921\"]]},\"colorway\":[\"#636efa\",\"#EF553B\",\"#00cc96\",\"#ab63fa\",\"#FFA15A\",\"#19d3f3\",\"#FF6692\",\"#B6E880\",\"#FF97FF\",\"#FECB52\"],\"font\":{\"color\":\"#2a3f5f\"},\"geo\":{\"bgcolor\":\"white\",\"lakecolor\":\"white\",\"landcolor\":\"#E5ECF6\",\"showlakes\":true,\"showland\":true,\"subunitcolor\":\"white\"},\"hoverlabel\":{\"align\":\"left\"},\"hovermode\":\"closest\",\"mapbox\":{\"style\":\"light\"},\"paper_bgcolor\":\"white\",\"plot_bgcolor\":\"#E5ECF6\",\"polar\":{\"angularaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"radialaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"scene\":{\"xaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"yaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"},\"zaxis\":{\"backgroundcolor\":\"#E5ECF6\",\"gridcolor\":\"white\",\"gridwidth\":2,\"linecolor\":\"white\",\"showbackground\":true,\"ticks\":\"\",\"zerolinecolor\":\"white\"}},\"shapedefaults\":{\"line\":{\"color\":\"#2a3f5f\"}},\"ternary\":{\"aaxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"baxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"},\"bgcolor\":\"#E5ECF6\",\"caxis\":{\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\"}},\"title\":{\"x\":0.05},\"xaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2},\"yaxis\":{\"automargin\":true,\"gridcolor\":\"white\",\"linecolor\":\"white\",\"ticks\":\"\",\"title\":{\"standoff\":15},\"zerolinecolor\":\"white\",\"zerolinewidth\":2}}},\"title\":{\"text\":\"Citations and income\"},\"xaxis\":{\"anchor\":\"y\",\"domain\":[0,0.42],\"showgrid\":true,\"showline\":false,\"showticklabels\":true,\"zeroline\":false},\"yaxis\":{\"anchor\":\"x\",\"domain\":[0,0.85],\"showticklabels\":true},\"xaxis2\":{\"anchor\":\"y2\",\"domain\":[0.47,1],\"dtick\":25,\"showgrid\":true,\"showline\":false,\"showticklabels\":true,\"side\":\"top\",\"zeroline\":false},\"yaxis2\":{\"anchor\":\"x2\",\"domain\":[0,0.85],\"linecolor\":\"rgba(102, 102, 102, 0.8)\",\"linewidth\":2,\"matches\":\"y\",\"showline\":true,\"showticklabels\":false}},                        {\"responsive\": true}                    ).then(function(){\n",
       "                            \n",
       "var gd = document.getElementById('54c75b99-d145-4ddb-9c00-d0c47c3d8547');\n",
       "var x = new MutationObserver(function (mutations, observer) {{\n",
       "        var display = window.getComputedStyle(gd).display;\n",
       "        if (!display || display === 'none') {{\n",
       "            console.log([gd, 'removed!']);\n",
       "            Plotly.purge(gd);\n",
       "            observer.disconnect();\n",
       "        }}\n",
       "}});\n",
       "\n",
       "// Listen for the removal of the full notebook cells\n",
       "var notebookContainer = gd.closest('#notebook-container');\n",
       "if (notebookContainer) {{\n",
       "    x.observe(notebookContainer, {childList: true});\n",
       "}}\n",
       "\n",
       "// Listen for the clearing of the current output cell\n",
       "var outputEl = gd.closest('.output');\n",
       "if (outputEl) {{\n",
       "    x.observe(outputEl, {childList: true});\n",
       "}}\n",
       "\n",
       "                        })                };                });            </script>        </div>"
      ]
     },
     "metadata": {},
     "output_type": "display_data"
    }
   ],
   "source": [
    "# import graph objects as \"go\" and import tools\n",
    "import plotly.graph_objs as go\n",
    "from plotly import tools\n",
    "import matplotlib.pyplot as plt\n",
    "# prepare data frames\n",
    "df2016 = timesData[timesData.year == 2016].iloc[:7,:]\n",
    "\n",
    "y_saving = [each for each in df2016.research]\n",
    "y_net_worth  = [float(each) for each in df2016.income]\n",
    "x_saving = [each for each in df2016.university_name]\n",
    "x_net_worth  = [each for each in df2016.university_name]\n",
    "trace0 = go.Bar(\n",
    "                x=y_saving,\n",
    "                y=x_saving,\n",
    "                marker=dict(color='rgba(171, 50, 96, 0.6)',line=dict(color='rgba(171, 50, 96, 1.0)',width=1)),\n",
    "                name='research',\n",
    "                orientation='h',\n",
    ")\n",
    "trace1 = go.Scatter(\n",
    "                x=y_net_worth,\n",
    "                y=x_net_worth,\n",
    "                mode='lines+markers',\n",
    "                line=dict(color='rgb(63, 72, 204)'),\n",
    "                name='income',\n",
    ")\n",
    "layout = dict(\n",
    "                title='Citations and income',\n",
    "                yaxis=dict(showticklabels=True,domain=[0, 0.85]),\n",
    "                yaxis2=dict(showline=True,showticklabels=False,linecolor='rgba(102, 102, 102, 0.8)',linewidth=2,domain=[0, 0.85]),\n",
    "                xaxis=dict(zeroline=False,showline=False,showticklabels=True,showgrid=True,domain=[0, 0.42]),\n",
    "                xaxis2=dict(zeroline=False,showline=False,showticklabels=True,showgrid=True,domain=[0.47, 1],side='top',dtick=25),\n",
    "                legend=dict(x=0.029,y=1.038,font=dict(size=10) ),\n",
    "                margin=dict(l=200, r=20,t=70,b=70),\n",
    "                paper_bgcolor='rgb(248, 248, 255)',\n",
    "                plot_bgcolor='rgb(248, 248, 255)',\n",
    ")\n",
    "annotations = []\n",
    "y_s = np.round(y_saving, decimals=2)\n",
    "y_nw = np.rint(y_net_worth)\n",
    "# Adding labels\n",
    "for ydn, yd, xd in zip(y_nw, y_s, x_saving):\n",
    "    # labeling the scatter savings\n",
    "    annotations.append(dict(xref='x2', yref='y2', y=xd, x=ydn - 4,text='{:,}'.format(ydn),font=dict(family='Arial', size=12,color='rgb(63, 72, 204)'),showarrow=False))\n",
    "    # labeling the bar net worth\n",
    "    annotations.append(dict(xref='x1', yref='y1', y=xd, x=yd + 3,text=str(yd),font=dict(family='Arial', size=12,color='rgb(171, 50, 96)'),showarrow=False))\n",
    "\n",
    "layout['annotations'] = annotations\n",
    "\n",
    "# Creating two subplots\n",
    "fig = tools.make_subplots(rows=1, cols=2, specs=[[{}, {}]], shared_xaxes=False,\n",
    "                          shared_yaxes=True, vertical_spacing=0.001)\n",
    "\n",
    "fig.append_trace(trace0, 1, 1)\n",
    "fig.append_trace(trace1, 1, 2)\n",
    "\n",
    "fig['layout'].update(layout)\n",
    "iplot(fig)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "myven",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.11.7"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
